[PATCH] ethdev: introduce generic dummy packet burst function

Andrew Rybchenko andrew.rybchenko at oktetlabs.ru
Thu Feb 10 12:51:31 CET 2022


On 2/10/22 14:47, Morten Brørup wrote:
>> From: Andrew Rybchenko [mailto:andrew.rybchenko at oktetlabs.ru]
>> Sent: Thursday, 10 February 2022 12.39
>>
>> On 2/10/22 14:04, Morten Brørup wrote:
>>>> From: Ferruh Yigit [mailto:ferruh.yigit at intel.com]
>>>> Sent: Tuesday, 8 February 2022 20.45
>>>>
>>>> Multiple PMDs have dummy/noop Rx/Tx packet burst functions.
>>>>
>>>> These dummy functions are very simple, introduce a common function
>> in
>>>> the ethdev and update drivers to use it instead of each driver
>> having
>>>> its own functions.
>>>>
>>>> Signed-off-by: Ferruh Yigit <ferruh.yigit at intel.com>
>>>
>>> After briefly considering if the dummy TX should free the burst, I
>> concluded that the current behavior is correct.
>>
>> Could you share your thoughts, please. I'm wondering as well.
> 
> Returning 0 means that the packets were not transmitted.
> 
> This leaves it up to the application to decide what to do: drop or retransmit.
> 
> If the dummy TX function frees the burst, it would effectively mean that the driver dropped the packets. (In that case, some drop counters should probably also be updated in the driver; but that is irrelevant now.)

Makes sense, thank you.

> 
> Not dropping the packets could be significant during startup.
> 
>>
>>>
>>> Good clean-up. :-)
>>>
>>> Acked-by: Morten Brørup <mb at smartsharesystems.com>
>>>
>>
> 



More information about the dev mailing list