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: <MN2PR11MB40452D36C68C6F20D9925AA6EAB39@MN2PR11MB4045.namprd11.prod.outlook.com>
Date:   Fri, 3 Mar 2023 17:14:16 +0000
From:   "Rout, ChandanX" <chandanx.rout@...el.com>
To:     "Sarkar, Tirthendu" <tirthendu.sarkar@...el.com>,
        "intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>
CC:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "Brandeburg, Jesse" <jesse.brandeburg@...el.com>,
        "Nguyen, Anthony L" <anthony.l.nguyen@...el.com>,
        "bpf@...r.kernel.org" <bpf@...r.kernel.org>,
        "Karlsson, Magnus" <magnus.karlsson@...el.com>,
        "Kuruvinakunnel, George" <george.kuruvinakunnel@...el.com>,
        "Nagaraju, Shwetha" <shwetha.nagaraju@...el.com>,
        "Nagraj, Shravan" <shravan.nagraj@...el.com>
Subject: RE: [Intel-wired-lan] [PATCH intel-next v6 8/8] i40e: add support for
 XDP multi-buffer Rx



>-----Original Message-----
>From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of
>Sarkar, Tirthendu
>Sent: 18 February 2023 00:45
>To: intel-wired-lan@...ts.osuosl.org
>Cc: Sarkar, Tirthendu <tirthendu.sarkar@...el.com>; netdev@...r.kernel.org;
>Brandeburg, Jesse <jesse.brandeburg@...el.com>; Nguyen, Anthony L
><anthony.l.nguyen@...el.com>; bpf@...r.kernel.org; Karlsson, Magnus
><magnus.karlsson@...el.com>
>Subject: [Intel-wired-lan] [PATCH intel-next v6 8/8] i40e: add support for XDP
>multi-buffer Rx
>
>This patch adds multi-buffer support for the i40e_driver.
>
>i40e_clean_rx_irq() is modified to collate all the buffers of a packet before
>calling the XDP program. xdp_buff is built for the first frag of the packet and
>subsequent frags are added to it. 'next_to_process' is incremented for all
>non-EOP frags while 'next_to_clean' stays at the first descriptor of the packet.
>XDP program is called only on receiving EOP frag.
>
>New functions are added for adding frags to xdp_buff and for post processing
>of the buffers once the xdp prog has run. For XDP_PASS this results in a skb
>with multiple fragments.
>
>i40e_build_skb() builds the skb around xdp buffer that already contains frags
>data. So i40e_add_rx_frag() helper function is now removed. Since fields
>before 'dataref' in skb_shared_info are cleared during napi_skb_build(),
>xdp_update_skb_shared_info() is called to set those.
>
>For i40e_construct_skb(), all the frags data needs to be copied from
>xdp_buffer's shared_skb_info to newly constructed skb's shared_skb_info.
>
>This also means 'skb' does not need to be preserved across i40e_napi_poll()
>calls and hence is removed from i40e_ring structure.
>
>Previously i40e_alloc_rx_buffers() was called for every 32 cleaned buffers. For
>multi-buffers this may not be optimal as there may be more cleaned buffers
>in each i40e_clean_rx_irq() call. So this is now called when at least half of the
>ring size has been cleaned.
>
>Signed-off-by: Tirthendu Sarkar <tirthendu.sarkar@...el.com>
>---
> drivers/net/ethernet/intel/i40e/i40e_main.c |   7 +-
> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 316 +++++++++++++-------
> drivers/net/ethernet/intel/i40e/i40e_txrx.h |   8 -
> 3 files changed, 212 insertions(+), 119 deletions(-)
>

Tested-by: Chandan Kumar Rout <chandanx.rout@...el.com> (A Contingent Worker at Intel)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ