lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <SJ0PR11MB5865582655B88ADFDFB4393D8F512@SJ0PR11MB5865.namprd11.prod.outlook.com>
Date: Mon, 4 Nov 2024 11:04:27 +0000
From: "Romanowski, Rafal" <rafal.romanowski@...el.com>
To: "Polchlopek, Mateusz" <mateusz.polchlopek@...el.com>,
	"intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>, "Keller, Jacob E"
	<jacob.e.keller@...el.com>, "Polchlopek, Mateusz"
	<mateusz.polchlopek@...el.com>
Subject: RE: [Intel-wired-lan] [PATCH iwl-next v12 11/14] iavf: refactor
 iavf_clean_rx_irq to support legacy and flex descriptors

> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of
> Mateusz Polchlopek
> Sent: Tuesday, October 22, 2024 1:41 PM
> To: intel-wired-lan@...ts.osuosl.org
> Cc: netdev@...r.kernel.org; Keller, Jacob E <jacob.e.keller@...el.com>;
> Polchlopek, Mateusz <mateusz.polchlopek@...el.com>
> Subject: [Intel-wired-lan] [PATCH iwl-next v12 11/14] iavf: refactor
> iavf_clean_rx_irq to support legacy and flex descriptors
> 
> From: Jacob Keller <jacob.e.keller@...el.com>
> 
> Using VIRTCHNL_VF_OFFLOAD_FLEX_DESC, the iAVF driver is capable of
> negotiating to enable the advanced flexible descriptor layout. Add the flexible
> NIC layout (RXDID=2) as a member of the Rx descriptor union.
> 
> Also add bit position definitions for the status and error indications that are
> needed.
> 
> The iavf_clean_rx_irq function needs to extract a few fields from the Rx
> descriptor, including the size, rx_ptype, and vlan_tag.
> Move the extraction to a separate function that decodes the fields into a
> structure. This will reduce the burden for handling multiple descriptor types by
> keeping the relevant extraction logic in one place.
> 
> To support handling an additional descriptor format with minimal code
> duplication, refactor Rx checksum handling so that the general logic is separated
> from the bit calculations. Introduce an iavf_rx_desc_decoded structure which
> holds the relevant bits decoded from the Rx descriptor.
> This will enable implementing flexible descriptor handling without duplicating the
> general logic twice.
> 
> Introduce an iavf_extract_flex_rx_fields, iavf_flex_rx_hash, and
> iavf_flex_rx_csum functions which operate on the flexible NIC descriptor format
> instead of the legacy 32 byte format. Based on the negotiated RXDID, select the
> correct function for processing the Rx descriptors.
> 
> With this change, the Rx hot path should be functional when using either the
> default legacy 32byte format or when we switch to the flexible NIC layout.
> 
> Modify the Rx hot path to add support for the flexible descriptor format and add
> request enabling Rx timestamps for all queues.
> 
> As in ice, make sure we bump the checksum level if the hardware detected a
> packet type which could have an outer checksum. This is important because
> hardware only verifies the inner checksum.
> 
> Signed-off-by: Jacob Keller <jacob.e.keller@...el.com>
> Co-developed-by: Mateusz Polchlopek <mateusz.polchlopek@...el.com>
> Signed-off-by: Mateusz Polchlopek <mateusz.polchlopek@...el.com>
> ---
>  drivers/net/ethernet/intel/iavf/iavf_txrx.c | 354 ++++++++++++++------
> drivers/net/ethernet/intel/iavf/iavf_type.h | 127 ++++---
>  2 files changed, 327 insertions(+), 154 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> index 46745ebc9c1f..89b71509e521 100644
> --- a/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> +++ b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> @@ -896,59 +896,43 @@ bool iavf_alloc_rx_buffers(struct iavf_ring *rx_ring,


Tested-by: Rafal Romanowski <rafal.romanowski@...el.com>



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ