On 10/12/20 3:22 PM, Andrew Rybchenko wrote: > On 10/12/20 2:30 PM, Nipun Gupta wrote: >>> -----Original Message----- >>> From: Andrew Rybchenko <[email protected]> >>> Sent: Monday, October 12, 2020 1:32 PM >>> To: Nipun Gupta <[email protected]>; [email protected] >>> Cc: [email protected]; [email protected]; [email protected]; >>> Hemant Agrawal <[email protected]>; Sachin Saxena >>> <[email protected]>; Rohit Raj <[email protected]>; >>> [email protected]; [email protected]; [email protected] >>> Subject: Re: [dpdk-dev] [PATCH 1/3 v3] ethdev: add rx offload to drop error >>> packets >>> >>> On 10/9/20 4:13 PM, [email protected] wrote: >>>> From: Nipun Gupta <[email protected]> >>>> >>>> This change adds a RX offload capability and configuration to >>>> enable hardware to drop the packets in case of any error in the >>>> packets such as L3 checksum error or L4 checksum. >>>> >>>> Signed-off-by: Nipun Gupta <[email protected]> >>>> Signed-off-by: Rohit Raj <[email protected]> >>>> Reviewed-by: Asaf Penso <[email protected]>
Thinking a bit more about it I agree with Thomas idea that it should be flow API based solution in fact. Drop is just a one of possible actions to be done with packets with bad checksum on one or another layer. Such packets could be redirected to a slow path (dedicated queue or port ID (PF, VF)). It is just a missing feature in various layer pattern match to say if we want to proceed with packets with only good or only bad chehcksum (or we don't care as we do right now). Exact match for checksums is hardly useful except UDP with zero checksum case.

