[dpdk-stable] [PATCH v1 1/1] test/distributor: prevent return buffer overload

Lukasz Wojciechowski l.wojciechow at partner.samsung.com
Fri Jan 29 13:36:58 CET 2021


Thank you guys!

W dniu 29.01.2021 o 09:03, David Marchand pisze:
> On Thu, Jan 28, 2021 at 3:10 PM David Marchand
> <david.marchand at redhat.com> wrote:
>> On Tue, Jan 19, 2021 at 4:59 AM Lukasz Wojciechowski
>> <l.wojciechow at partner.samsung.com> wrote:
>>> The distributor library implementation uses a cyclic queue to store
>>> packets returned from workers. These packets can be later collected
>>> with rte_distributor_returned_pkts() call.
>>> However the queue has limited capacity. It is able to contain only
>>> 127 packets (RTE_DISTRIB_RETURNS_MASK).
>>>
>>> Big burst tests sent 1024 packets in 32 packets bursts without waiting
>>> until they are processed by the distributor. In case when tests were
>>> run with big number of worker threads, it happened that more than
>>> 127 packets were returned from workers and put into cyclic queue.
>>> This caused packets to be dropped by the queue, making them impossible
>>> to be collected later with rte_distributor_returned_pkts() calls.
>>> However the test waited for all packets to be returned infinitely.
>>>
>>> This patch fixes the big burst test by not allowing more than
>>> queue capacity packets to be processed at the same time, making
>>> impossible to drop any packets.
>>> It also cleans up duplicated code in the same test.
>>>
>>> Bugzilla ID: 612
>>> Fixes: c0de0eb82e40 ("distributor: switch over to new API")
>>> Cc: stable at dpdk.org
>>>
>>> Signed-off-by: Lukasz Wojciechowski <l.wojciechow at partner.samsung.com>
>> Tested-by: David Marchand <david.marchand at redhat.com>
> Reviewed-by: David Hunt <david.hunt at intel.com>
>
> Applied, thanks Lukasz.
>
> This should fix the issue seen at UNH on the ARM server.
>
-- 
Lukasz Wojciechowski
Principal Software Engineer

Samsung R&D Institute Poland
Samsung Electronics
Office +48 22 377 88 25
l.wojciechow at partner.samsung.com



More information about the stable mailing list