Re: [Intel-wired-lan] [PATCH iwl-next v3 16/18] idpf: add support for XDP on Rx

2025-08-05 Thread Alexander Lobakin
From: Jakub Kicinski Date: Fri, 1 Aug 2025 15:33:43 -0700 > On Wed, 30 Jul 2025 18:07:15 +0200 Alexander Lobakin wrote: >> Use __LIBETH_WORD_ACCESS to parse descriptors more efficiently when >> applicable. It really gives some good boosts and code size reduction >> on x

Re: [Intel-wired-lan] [PATCH iwl-next v3 13/18] idpf: prepare structures to support XDP

2025-08-05 Thread Alexander Lobakin
From: Jakub Kicinski Date: Fri, 1 Aug 2025 15:30:23 -0700 > On Wed, 30 Jul 2025 18:07:12 +0200 Alexander Lobakin wrote: >> Note that "other count" in Ethtool will now also include XDP Tx queues. > > Erm, what? You mean other channels? Channels are interrupts, >

Re: [Intel-wired-lan] [PATCH iwl-net v3 4/6] idpf: replace flow scheduling buffer ring with buffer pool

2025-08-04 Thread Alexander Lobakin
From: Joshua Hay Date: Fri, 25 Jul 2025 11:42:21 -0700 > Replace the TxQ buffer ring with one large pool/array of buffers (only > for flow scheduling). This eliminates the tag generation and makes it > impossible for a tag to be associated with more than one packet. [...] > -static bool idpf_tx

Re: [Intel-wired-lan] [PATCH iwl-next v3 16/18] idpf: add support for XDP on Rx

2025-08-01 Thread Alexander Lobakin
From: Alexander Lobakin Date: Fri, 1 Aug 2025 15:12:43 +0200 > From: Kees Cook > Date: Thu, 31 Jul 2025 10:05:47 -0700 > >> On Thu, Jul 31, 2025 at 01:37:34PM +0100, Simon Horman wrote: >>> While I appreciate the desire for improved performance and nicer code >>

Re: [Intel-wired-lan] [PATCH iwl-next v3 16/18] idpf: add support for XDP on Rx

2025-08-01 Thread Alexander Lobakin
From: Kees Cook Date: Thu, 31 Jul 2025 10:05:47 -0700 > On Thu, Jul 31, 2025 at 01:37:34PM +0100, Simon Horman wrote: >> While I appreciate the desire for improved performance and nicer code >> generation. I think the idea of writing 64 bits of data to the >> address of a 32 bit member of a struc

Re: [Intel-wired-lan] [PATCH iwl-next v3 16/18] idpf: add support for XDP on Rx

2025-08-01 Thread Alexander Lobakin
From: Simon Horman Date: Thu, 31 Jul 2025 14:35:57 +0100 > On Wed, Jul 30, 2025 at 06:07:15PM +0200, Alexander Lobakin wrote: >> Use libeth XDP infra to support running XDP program on Rx polling. >> This includes all of the possible verdicts/actions. >> XDP Tx queues are

[Intel-wired-lan] [PATCH iwl-next v3 18/18] idpf: add XDP RSS hash hint

2025-07-30 Thread Alexander Lobakin
Add &xdp_metadata_ops with a callback to get RSS hash hint from the descriptor. Declare the splitq 32-byte descriptor as 4 u64s to parse them more efficiently when possible. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/xdp.h | 64 +++ drivers

[Intel-wired-lan] [PATCH iwl-next v3 17/18] idpf: add support for .ndo_xdp_xmit()

2025-07-30 Thread Alexander Lobakin
ki Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/xdp.h | 2 ++ drivers/net/ethernet/intel/idpf/idpf_lib.c | 1 + drivers/net/ethernet/intel/idpf/xdp.c | 20 3 files changed, 23 insertions(+) diff --git a/drivers/net/ethernet/intel/idp

[Intel-wired-lan] [PATCH iwl-next v3 16/18] idpf: add support for XDP on Rx

2025-07-30 Thread Alexander Lobakin
tions make sure the compiler could uninline them when needed. Use __LIBETH_WORD_ACCESS to parse descriptors more efficiently when applicable. It really gives some good boosts and code size reduction on x86_64. Co-developed-by: Michal Kubiak Signed-off-by: Michal Kubiak Signed-off-by: Alexand

[Intel-wired-lan] [PATCH iwl-next v3 15/18] idpf: use generic functions to build xdp_buff and skb

2025-07-30 Thread Alexander Lobakin
d to the frame. Store &libeth_xdp_stash instead of the skb pointer on the Rx queue. It's only 8 bytes wider, but contains everything we may need. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 17 +- .../ethernet/intel/idpf/idpf_singleq_t

[Intel-wired-lan] [PATCH iwl-next v3 14/18] idpf: implement XDP_SETUP_PROG in ndo_bpf for splitq

2025-07-30 Thread Alexander Lobakin
From: Michal Kubiak Implement loading/removing XDP program using .ndo_bpf callback in the split queue mode. Reconfigure and restart the queues if needed (!!old_prog != !!new_prog), otherwise, just update the pointers. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers

[Intel-wired-lan] [PATCH iwl-next v3 13/18] idpf: prepare structures to support XDP

2025-07-30 Thread Alexander Lobakin
h regular Tx traffic. Also add functions dedicated to support XDP initialization for Rx and Tx queues and call those functions from the existing algorithms of queues configuration. Note that "other count" in Ethtool will now also include XDP Tx queues. Signed-off-by: Michal Kubiak Co-dev

[Intel-wired-lan] [PATCH iwl-next v3 12/18] idpf: add support for nointerrupt queues

2025-07-30 Thread Alexander Lobakin
creating vport, so that it can be used later by queues when needed (not only XDP ones). Co-developed-by: Michal Kubiak Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf.h| 8 +++ drivers/net/ethernet/intel/idpf/idpf_txrx.h | 4 ++ dr

[Intel-wired-lan] [PATCH iwl-next v3 11/18] idpf: remove SW marker handling from NAPI

2025-07-30 Thread Alexander Lobakin
t for the replies. If replies for all of the queues are received, this means the synchronization is done correctly and we can go forth with stopping the link. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf.h| 7 +- drivers/net/eth

[Intel-wired-lan] [PATCH iwl-next v3 10/18] idpf: add 4-byte completion descriptor definition

2025-07-30 Thread Alexander Lobakin
completions during Tx polling, as for now, the only user of QB will be XDP, which has its own routines. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- .../net/ethernet/intel/idpf/idpf_lan_txrx.h | 6 +++- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 11 -- drivers/net

[Intel-wired-lan] [PATCH iwl-next v3 08/18] idpf: use a saner limit for default number of queues to allocate

2025-07-30 Thread Alexander Lobakin
/enable/disable large amount of queues within the minimum timeout (2 seconds). For now, fall back to the default timeout for every operation until this is resolved. Signed-off-by: Alexander Lobakin --- .../net/ethernet/intel/idpf/idpf_virtchnl.h | 1 - drivers/net/ethernet/intel/idpf/idp

[Intel-wired-lan] [PATCH iwl-next v3 09/18] idpf: link NAPIs to queues

2025-07-30 Thread Alexander Lobakin
ken, needs it. Expand common idpf_vport_{start,stop}() to take an additional bool telling whether we need to manually take the RTNL lock. Suggested-by: Maciej Fijalkowski # helper Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_lib.c | 38 +++-- driv

[Intel-wired-lan] [PATCH iwl-next v3 07/18] idpf: fix Rx descriptor ready check barrier in splitq

2025-07-30 Thread Alexander Lobakin
need to stop polling. Debatable on coherent DMA as the Rx descriptor size is <= cacheline size, but anyway, the current barrier position only makes the codegen worse. Fixes: 3a8845af66ed ("idpf: add RX splitq napi poll support") Reviewed-by: Maciej Fijalkowski Signed-off-by: Alex

[Intel-wired-lan] [PATCH iwl-next v3 06/18] idpf: remove obsolete stashing code

2025-07-30 Thread Alexander Lobakin
From: Joshua Hay With the new Tx buffer management scheme, there is no need for all of the stashing mechanisms, the hash table, the reserve buffer stack, etc. Remove all of that. Signed-off-by: Joshua Hay Reviewed-by: Madhu Chittim Signed-off-by: Alexander Lobakin --- drivers/net/ethernet

[Intel-wired-lan] [PATCH iwl-next v3 04/18] idpf: replace flow scheduling buffer ring with buffer pool

2025-07-30 Thread Alexander Lobakin
hua Hay Reviewed-by: Madhu Chittim Reviewed-by: Aleksandr Loktionov Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 10 +- drivers/net/ethernet/intel/idpf/idpf_txrx.c | 203 +--- 2 files changed, 102 insertions(+), 111 deletions(-) diff

[Intel-wired-lan] [PATCH iwl-next v3 05/18] idpf: stop Tx if there are insufficient buffer resources

2025-07-30 Thread Alexander Lobakin
resources to send the packet, and stop the queue if not. Fixes: 7292af042bcf ("idpf: fix a race in txq wakeup") Signed-off-by: Joshua Hay Reviewed-by: Madhu Chittim Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 15 +- .../ethernet/

[Intel-wired-lan] [PATCH iwl-next v3 02/18] idpf: improve when to set RE bit logic

2025-07-30 Thread Alexander Lobakin
r advance. The previous implementation was dependent on the start of a packet falling on a 64th index in the descriptor ring, which is not guaranteed with large packets. Signed-off-by: Luigi Rizzo Signed-off-by: Brian Vazquez Signed-off-by: Joshua Hay Reviewed-by: Madhu Chittim Signed-off-by: Al

[Intel-wired-lan] [PATCH iwl-next v3 03/18] idpf: simplify and fix splitq Tx packet rollback error path

2025-07-30 Thread Alexander Lobakin
the PTP context descriptor. Fixes: 1a49cf814fe1 ("idpf: add Tx timestamp flows") Signed-off-by: Joshua Hay Reviewed-by: Madhu Chittim Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 5 +- .../ethernet/intel/idpf/idpf_singleq_txr

[Intel-wired-lan] [PATCH iwl-next v3 00/18] idpf: add XDP support

2025-07-30 Thread Alexander Lobakin
arios. idpf doesn't support VLAN Rx offload, so only the hash hint is available for now. Patches 1-6 are prereqs, without which XDP would either not work at all or work slower/worse/... Alexander Lobakin (8): idpf: fix Rx descriptor ready check barrier in splitq idpf: use a saner limit f

[Intel-wired-lan] [PATCH iwl-next v3 01/18] idpf: add support for Tx refillqs in flow scheduling mode

2025-07-30 Thread Alexander Lobakin
: Madhu Chittim Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 8 +- drivers/net/ethernet/intel/idpf/idpf_txrx.c | 93 +++-- 2 files changed, 91 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/intel/idpf/idpf_txrx.h b/drivers/net

Re: [Intel-wired-lan] [PATCH iwl-next] idpf: set napi for each TX and RX queue

2025-07-18 Thread Alexander Lobakin
From: Tony Nguyen Date: Thu, 17 Jul 2025 13:25:05 -0700 > > > On 7/16/2025 2:12 PM, Samiullah Khawaja wrote: >> Use netif_queue_set_napi to associate TX/RX queues to the relevant napi. >> This allows fetching napi for a TX or RX queue using netlink queue-get >> op. >> >> Tested: >> python3 tool

Re: [Intel-wired-lan] [PATCH 1/1] idpf: Add missing dependencies

2025-07-14 Thread Alexander Lobakin
From: Przemek Kitszel Date: Fri, 11 Jul 2025 12:25:09 +0200 > On 7/11/25 08:47, Malin Jonsson wrote: >> The idpf driver depends on both AUXILIARY_BUS and NET_DEVLINK, but >> they're not selected by the Kconfig. Let's fix this so idpf builds even >> with a stripped config. >> >> Reported-by: Yong

Re: [Intel-wired-lan] [PATCH iwl-next 0/3] ice: convert Rx path to Page Pool

2025-07-14 Thread Alexander Lobakin
From: Jacob Keller Date: Thu, 10 Jul 2025 15:43:20 -0700 > > > On 7/7/2025 4:36 PM, Jacob Keller wrote: [...] > I got this to work with the following diff: > > diff --git i/drivers/net/ethernet/intel/ice/ice_txrx.h > w/drivers/net/ethernet/intel/ice/ice_txrx.h > index 42e74925b9df..6b72608a2

[Intel-wired-lan] [PATCH iwl-next] idpf: fix driver probe with CONFIG_LOCKDEP=y

2025-07-01 Thread Alexander Lobakin
all(), where rxq->q_vector is always initialized already. Signed-off-by: Alexander Lobakin --- To Tony: this is a hotfix for "idpf: implement XDP_SETUP_PROG in ndo_bpf for splitq" where this call was introduced, please squash. --- drivers/net/ethernet/intel/idpf/idpf_txrx.c | 4 ++-- 1

Re: [Intel-wired-lan] [PATCH net 4/5] idpf: stop Tx if there are insufficient buffer resources

2025-06-27 Thread Alexander Lobakin
From: Joshua Hay Date: Wed, 25 Jun 2025 09:11:55 -0700 > The Tx refillq logic will cause packets to be silently dropped if there > are not enough buffer resources available to send a packet in flow > scheduling mode. Instead, determine how many buffers are needed along > with number of descriptor

Re: [Intel-wired-lan] [PATCH net 1/5] idpf: add support for Tx refillqs in flow scheduling mode

2025-06-27 Thread Alexander Lobakin
From: Joshua Hay Date: Wed, 25 Jun 2025 09:11:52 -0700 > This is the start of a 5 patch series intended to fix a stability issue > in the flow scheduling Tx send/clean path that results in a Tx timeout. No need to mention "series", "start", "patch" in commit messages. > > In certain production

Re: [Intel-wired-lan] [PATCH net 3/5] idpf: replace flow scheduling buffer ring with buffer pool

2025-06-27 Thread Alexander Lobakin
From: Joshua Hay Date: Wed, 25 Jun 2025 09:11:54 -0700 > Replace the TxQ buffer ring with one large pool/array of buffers (only > for flow scheduling). The completion tag passed to HW through the [...] > diff --git a/drivers/net/ethernet/intel/idpf/idpf_txrx.c > b/drivers/net/ethernet/intel/id

Re: [Intel-wired-lan] [PATCH] [v2] ethernet: intel: fix building with large NR_CPUS

2025-06-25 Thread Alexander Lobakin
from the start > of the structure. Move this member before the CPU mask instead, in all three > drivers. > > Signed-off-by: Arnd Bergmann Reviewed-by: Alexander Lobakin > --- > v2: move rcu to just after the napi_struct [Alexander Lobakin] Thanks! Olek

[Intel-wired-lan] [PATCH iwl-next v2 00/12] idpf: add XDP support

2025-06-24 Thread Alexander Lobakin
arios. idpf doesn't support VLAN Rx offload, so only the hash hint is available for now. Patches 1-6 are prereqs, without which XDP would either not work at all or work slower/worse/... Alexander Lobakin (8): idpf: fix Rx descriptor ready check barrier in splitq idpf: use a saner limit f

[Intel-wired-lan] [PATCH iwl-next v2 11/12] idpf: add support for .ndo_xdp_xmit()

2025-06-24 Thread Alexander Lobakin
ki Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/xdp.h | 2 ++ drivers/net/ethernet/intel/idpf/idpf_lib.c | 1 + drivers/net/ethernet/intel/idpf/xdp.c | 20 3 files changed, 23 insertions(+) diff --git a/drivers/net/ethernet/intel/idp

[Intel-wired-lan] [PATCH iwl-next v2 03/12] idpf: link NAPIs to queues

2025-06-24 Thread Alexander Lobakin
mod, which happens outside of RTNL context, but calls idpf_vport_stop() which assumes RTNL protection. Suggested-by: Maciej Fijalkowski # helper Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_lib.c | 2 ++ drivers/net/ethernet/intel/idpf/idpf_txrx.c |

[Intel-wired-lan] [PATCH iwl-next v2 12/12] idpf: add XDP RSS hash hint

2025-06-24 Thread Alexander Lobakin
Add &xdp_metadata_ops with a callback to get RSS hash hint from the descriptor. Declare the splitq 32-byte descriptor as 4 u64s to parse them more efficiently when possible. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/xdp.h | 64 +++ drivers

[Intel-wired-lan] [PATCH iwl-next v2 09/12] idpf: use generic functions to build xdp_buff and skb

2025-06-24 Thread Alexander Lobakin
d to the frame. Store &libeth_xdp_stash instead of the skb pointer on the Rx queue. It's only 8 bytes wider, but contains everything we may need. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 17 +- .../ethernet/intel/idpf/idpf_singleq_t

[Intel-wired-lan] [PATCH iwl-next v2 01/12] idpf: fix Rx descriptor ready check barrier in splitq

2025-06-24 Thread Alexander Lobakin
need to stop polling. Debatable on coherent DMA as the Rx descriptor size is <= cacheline size, but anyway, the current barrier position only makes the codegen worse. Fixes: 3a8845af66ed ("idpf: add RX splitq napi poll support") Reviewed-by: Maciej Fijalkowski Signed-off-by: Alex

[Intel-wired-lan] [PATCH iwl-next v2 10/12] idpf: add support for XDP on Rx

2025-06-24 Thread Alexander Lobakin
tions make sure the compiler could uninline them when needed. Use __LIBETH_WORD_ACCESS to parse descriptors more efficiently when applicable. It really gives some good boosts and code size reduction on x86_64. Co-developed-by: Michal Kubiak Signed-off-by: Michal Kubiak Signed-off-by: Alexand

[Intel-wired-lan] [PATCH iwl-next v2 08/12] idpf: implement XDP_SETUP_PROG in ndo_bpf for splitq

2025-06-24 Thread Alexander Lobakin
From: Michal Kubiak Implement loading/removing XDP program using .ndo_bpf callback in the split queue mode. Reconfigure and restart the queues if needed (!!old_prog != !!new_prog), otherwise, just update the pointers. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers

[Intel-wired-lan] [PATCH iwl-next v2 07/12] idpf: prepare structures to support XDP

2025-06-24 Thread Alexander Lobakin
h regular Tx traffic. Also add functions dedicated to support XDP initialization for Rx and Tx queues and call those functions from the existing algorithms of queues configuration. Note that "other count" in Ethtool will now also include XDP Tx queues. Signed-off-by: Michal Kubiak Co-dev

[Intel-wired-lan] [PATCH iwl-next v2 06/12] idpf: add support for nointerrupt queues

2025-06-24 Thread Alexander Lobakin
creating vport, so that it can be used later by queues when needed (not only XDP ones). Co-developed-by: Michal Kubiak Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf.h| 8 +++ drivers/net/ethernet/intel/idpf/idpf_txrx.h | 4 ++ dr

[Intel-wired-lan] [PATCH iwl-next v2 05/12] idpf: remove SW marker handling from NAPI

2025-06-24 Thread Alexander Lobakin
t for the replies. If replies for all of the queues are received, this means the synchronization is done correctly and we can go forth with stopping the link. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf.h| 7 +- drivers/net/eth

[Intel-wired-lan] [PATCH iwl-next v2 02/12] idpf: use a saner limit for default number of queues to allocate

2025-06-24 Thread Alexander Lobakin
that anyhow. On a 128-thread Xeon, this now gives me 32 regular Tx queues and leaves 224 free for XDP (128 of which will handle XDP_TX, .ndo_xdp_xmit(), and XSk xmit when enabled). Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/idpf/idpf_txrx.c | 8 +--- drivers/net/eth

[Intel-wired-lan] [PATCH iwl-next v2 04/12] idpf: add 4-byte completion descriptor definition

2025-06-24 Thread Alexander Lobakin
completions during Tx polling, as for now, the only user of QB will be XDP, which has its own routines. Signed-off-by: Michal Kubiak Signed-off-by: Alexander Lobakin --- .../net/ethernet/intel/idpf/idpf_lan_txrx.h | 6 +++- drivers/net/ethernet/intel/idpf/idpf_txrx.h | 11 -- drivers/net

Re: [Intel-wired-lan] [PATCH] ethernet: intel: fix building with large NR_CPUS

2025-06-20 Thread Alexander Lobakin
From: Arnd Bergmann Date: Fri, 20 Jun 2025 13:11:17 +0200 > From: Arnd Bergmann > > With large values of CONFIG_NR_CPUS, three Intel ethernet drivers fail to > compile like: > > In function ‘i40e_free_q_vector’, > inlined from ‘i40e_vsi_alloc_q_vectors’ at > drivers/net/ethernet/intel/i40

Re: [Intel-wired-lan] [PATCH] igc: Make the const read-only array supported_sizes static

2025-06-18 Thread Alexander Lobakin
From: Colin Ian King Date: Wed, 18 Jun 2025 14:54:08 +0100 > Don't populate the const read-only array supported_sizes on the > stack at run time, instead make it static. > > Signed-off-by: Colin Ian King Reviewed-by: Alexander Lobakin > --- > drivers/net/ethernet/

[Intel-wired-lan] [PATCH iwl-next v2 17/17] libeth: xdp, xsk: access adjacent u32s as u64 where applicable

2025-06-12 Thread Alexander Lobakin
s on. There's a few places in libeth_xdp winning up to several percent from combined access (both performance and object code size, especially when unrolling). Add __LIBETH_WORD_ACCESS and use it there on LE. Drivers are free to optimize HW-specific callbacks under the same definition. Sign

[Intel-wired-lan] [PATCH iwl-next v2 16/17] libeth: xsk: add XSkFQ refill and XSk wakeup helpers

2025-06-12 Thread Alexander Lobakin
o provides better control for userspace on which CPU will handle the xmit, as SW interrupts honor IRQ affinity no matter which core produces XSk xmit descs (while XDPSQs are associated 1:1 with cores having the same ID). Signed-off-by: Alexander Lobakin --- include/net/libeth/xsk.h

[Intel-wired-lan] [PATCH iwl-next v2 14/17] libeth: xsk: add XSk xmit functions

2025-06-12 Thread Alexander Lobakin
he same file where dev->xsk_tx_metadata_ops gets set to avoid duplication of slowpath; at the same time; XSk xmit functions use local "fast" copy to inline XMO callbacks. Tx descriptor filling loop is unrolled by 8. Suggested-by: Maciej Fijalkowski # optimizations Signed-off-by: Alexander

[Intel-wired-lan] [PATCH iwl-next v2 11/17] libeth: xdp: add templates for building driver-side callbacks

2025-06-12 Thread Alexander Lobakin
. LIBETH_XDP_DEFINE_{BEGIN,END}() is needed for GCC 8+ unfortunately to let the drivers control which functions will be static and which global without hitting `-Wold-style-declaration`. Signed-off-by: Alexander Lobakin --- include/net/libeth/xdp.h | 195 +++ 1 file changed

[Intel-wired-lan] [PATCH iwl-next v2 13/17] libeth: xsk: add XSk XDP_TX sending helpers

2025-06-12 Thread Alexander Lobakin
ader split gives no benefits for XSk Rx, at least for now. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Kconfig | 2 +- drivers/net/ethernet/intel/libeth/Makefile | 1 + drivers/net/ethernet/intel/libeth/priv.h | 6 + include/net/libeth/tx.h|

[Intel-wired-lan] [PATCH iwl-next v2 08/17] libeth: xdp: add XDPSQ cleanup timers

2025-06-12 Thread Alexander Lobakin
of the last send. The timer is triggered when finalizing the queue. As long as there is regular active traffic, the timer doesn't fire. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 21 - include/net/libeth/xdp.h| 57

[Intel-wired-lan] [PATCH iwl-next v2 10/17] libeth: xdp: add XDP prog run and verdict result handling

2025-06-12 Thread Alexander Lobakin
the corresponding Rx queue structure via container_of(buff::rxq). If not, a driver can extend the buff with more fields directly on the stack without touching libeth_xdp definitions. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 22 ++ include/net/libeth/x

[Intel-wired-lan] [PATCH iwl-next v2 15/17] libeth: xsk: add XSk Rx processing support

2025-06-12 Thread Alexander Lobakin
gram presence as it's always true for XSk. Suggested-by: Maciej Fijalkowski # optimizations Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/priv.h | 3 + include/net/libeth/xdp.h | 17 +- include/net/libeth/xsk.h

[Intel-wired-lan] [PATCH iwl-next v2 07/17] libeth: xdp: add XDPSQ locking helpers

2025-06-12 Thread Alexander Lobakin
r the time of cleaning and filling the descriptors. As long as this particular queue is not used by more than 1 CPU, the impact is minimal (runtime check for boolean twice per 16+ descriptors). Suggested-by: Maciej Fijalkowski # static key Signed-off-by: Alexander Lobakin --- include/net/l

[Intel-wired-lan] [PATCH iwl-next v2 12/17] libeth: xdp: add RSS hash hint and XDP features setup helpers

2025-06-12 Thread Alexander Lobakin
End the XDP section by adding helpers to setup XDP features, flipping .ndo_xdp_xmit() support at runtime (in case when it's not always on), and calculating the queue clean/refill threshold. Signed-off-by: Alexander Lobakin --- include/net/libeth/xdp.h

[Intel-wired-lan] [PATCH iwl-next v2 05/17] libeth: xdp: add .ndo_xdp_xmit() helpers

2025-06-12 Thread Alexander Lobakin
n its headroom, assuming it has enough of it for an 8 (or 4) byte value. In addition to @prep and @xmit driver callbacks in XDP_TX, xmit also needs @finalize to kick the XDPSQ after filling. Signed-off-by: Alexander Lobakin --- include/net/libeth/tx.h | 6 + include/net/libeth/

intel-wired-lan@osuosl.org

2025-06-12 Thread Alexander Lobakin
here. Define a minimal structure, which would store only the fields essential to restore it. I was able to pack it into 16 bytes, which is only 8 bytes bigger than `struct sk_buff *skb` on x64. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 23 in

[Intel-wired-lan] [PATCH iwl-next v2 06/17] libeth: xdp: add XDPSQE completion helpers

2025-06-12 Thread Alexander Lobakin
we don't need inlining but convenience. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Makefile | 1 + include/net/libeth/types.h | 21 ++- drivers/net/ethernet/intel/libeth/priv.h | 26 + include/net/libeth/tx.h

[Intel-wired-lan] [PATCH iwl-next v2 04/17] libeth: xdp: add XDP_TX buffers sending

2025-06-12 Thread Alexander Lobakin
Suggested-by: Maciej Fijalkowski # xmit logic Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Kconfig | 10 +- drivers/net/ethernet/intel/libeth/Makefile | 6 +- include/net/libeth/tx.h| 11 +- include/net/libeth/xdp.h

[Intel-wired-lan] [PATCH iwl-next v2 02/17] libeth: convert to netmem

2025-06-12 Thread Alexander Lobakin
faster "unsafe" underscored netmem <--> virt accessors as netmem_is_net_iov() is always false in that case, but consumes some cycles (bit test + true branch). Reviewed-by: Mina Almasry Signed-off-by: Alexander Lobakin --- include/net/libeth/rx.h | 22 +++

[Intel-wired-lan] [PATCH iwl-next v2 03/17] libeth: support native XDP and register memory model

2025-06-12 Thread Alexander Lobakin
ed-off-by: Alexander Lobakin --- include/net/libeth/rx.h| 6 +- drivers/net/ethernet/intel/libeth/rx.c | 20 +++- 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/include/net/libeth/rx.h b/include/net/libeth/rx.h index 7d5dc58984b1..5d99140484

[Intel-wired-lan] [PATCH iwl-next v2 00/17] libeth: add libeth_xdp helper lib

2025-06-12 Thread Alexander Lobakin
sts here ("XDP for idpf"). Macros for building driver XDP functions lead to that some implementations (XDP_TX, ndo_xdp_xmit etc.) consist of really only a few lines. Alexander Lobakin (17): libeth, libie: clean symbol exports up a little libeth: convert to netmem libeth: support na

[Intel-wired-lan] [PATCH iwl-next v2 01/17] libeth, libie: clean symbol exports up a little

2025-06-12 Thread Alexander Lobakin
Change EXPORT_SYMBOL_NS_GPL(x, "LIBETH") to EXPORT_SYMBOL_GPL(x) + DEFAULT_SYMBOL_NAMESPACE "LIBETH" to make the code more compact. Also, explicitly include to satisfy new requirements from scripts/misc-check. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/in

Re: [Intel-wired-lan] [PATCH iwl-next 03/16] libeth: xdp: add XDP_TX buffers sending

2025-05-13 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Thu, 24 Apr 2025 14:48:39 +0200 > On Tue, Apr 15, 2025 at 07:28:12PM +0200, Alexander Lobakin wrote: >> Start adding XDP-specific code to libeth, namely handling XDP_TX buffers >> (only sending). [...] >> +static __always_inline u32 >&g

Re: [Intel-wired-lan] [PATCH iwl-next 01/16] libeth: convert to netmem

2025-04-17 Thread Alexander Lobakin
From: Loktionov, Aleksandr Date: Wed, 16 Apr 2025 08:54:39 +0200 > > >> -Original Message- >> From: Intel-wired-lan On Behalf Of >> Alexander Lobakin >> Sent: Tuesday, April 15, 2025 7:28 PM >> To: intel-wired-...@lists.osuosl.org >>

Re: [Intel-wired-lan] [PATCH iwl-next 00/14] Introduce iXD driver

2025-04-16 Thread Alexander Lobakin
From: Larysa Zaremba Date: Tue, 8 Apr 2025 14:47:46 +0200 > This patch series adds the iXD driver, which supports the Intel(R) > Control Plane PCI Function on Intel E2100 and later IPUs and FNICs. > It facilitates a centralized control over multiple IDPF PFs/VFs/SFs > exposed by the same card. Th

[Intel-wired-lan] [PATCH iwl-next 16/16] libeth: xdp, xsk: access adjacent u32s as u64 where applicable

2025-04-15 Thread Alexander Lobakin
s on. There's a few places in libeth_xdp winning up to several percent from combined access (both performance and object code size, especially when unrolling). Add __LIBETH_WORD_ACCESS and use it there on LE. Drivers are free to optimize HW-specific callbacks under the same definition. Sign

[Intel-wired-lan] [PATCH iwl-next 15/16] libeth: xsk: add XSkFQ refill and XSk wakeup helpers

2025-04-15 Thread Alexander Lobakin
o provides better control for userspace on which CPU will handle the xmit, as SW interrupts honor IRQ affinity no matter which core produces XSk xmit descs (while XDPSQs are associated 1:1 with cores having the same ID). Signed-off-by: Alexander Lobakin --- include/net/libeth/xsk.h

[Intel-wired-lan] [PATCH iwl-next 11/16] libeth: xdp: add RSS hash hint and XDP features setup helpers

2025-04-15 Thread Alexander Lobakin
End the XDP section by adding helpers to setup XDP features, flipping .ndo_xdp_xmit() support at runtime (in case when it's not always on), and calculating the queue clean/refill threshold. Signed-off-by: Alexander Lobakin --- include/net/libeth/xdp.h

[Intel-wired-lan] [PATCH iwl-next 14/16] libeth: xsk: add XSk Rx processing support

2025-04-15 Thread Alexander Lobakin
gram presence as it's always true for XSk. Suggested-by: Maciej Fijalkowski # optimizations Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/priv.h | 3 + include/net/libeth/xdp.h | 17 +- include/net/libeth/xsk.h

[Intel-wired-lan] [PATCH iwl-next 12/16] libeth: xsk: add XSk XDP_TX sending helpers

2025-04-15 Thread Alexander Lobakin
ader split gives no benefits for XSk Rx, at least for now. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Kconfig | 2 +- drivers/net/ethernet/intel/libeth/Makefile | 1 + drivers/net/ethernet/intel/libeth/priv.h | 6 + include/net/libeth/tx.h|

[Intel-wired-lan] [PATCH iwl-next 13/16] libeth: xsk: add XSk xmit functions

2025-04-15 Thread Alexander Lobakin
he same file where dev->xsk_tx_metadata_ops gets set to avoid duplication of slowpath; at the same time; XSk xmit functions use local "fast" copy to inline XMO callbacks. Tx descriptor filling loop is unrolled by 8. Suggested-by: Maciej Fijalkowski # optimizations Signed-off-by: Alexander

[Intel-wired-lan] [PATCH iwl-next 10/16] libeth: xdp: add templates for building driver-side callbacks

2025-04-15 Thread Alexander Lobakin
. LIBETH_XDP_DEFINE_{BEGIN,END}() is needed for GCC 8+ unfortunately to let the drivers control which functions will be static and which global without hitting `-Wold-style-declaration`. Signed-off-by: Alexander Lobakin --- include/net/libeth/xdp.h | 195 +++ 1 file changed

intel-wired-lan@osuosl.org

2025-04-15 Thread Alexander Lobakin
here. Define a minimal structure, which would store only the fields essential to restore it. I was able to pack it into 16 bytes, which is only 8 bytes bigger than `struct sk_buff *skb` on x64. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 23 in

[Intel-wired-lan] [PATCH iwl-next 09/16] libeth: xdp: add XDP prog run and verdict result handling

2025-04-15 Thread Alexander Lobakin
the corresponding Rx queue structure via container_of(buff::rxq). If not, a driver can extend the buff with more fields directly on the stack without touching libeth_xdp definitions. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 22 ++ include/net/libeth/x

[Intel-wired-lan] [PATCH iwl-next 06/16] libeth: xdp: add XDPSQ locking helpers

2025-04-15 Thread Alexander Lobakin
r the time of cleaning and filling the descriptors. As long as this particular queue is not used by more than 1 CPU, the impact is minimal (runtime check for boolean twice per 16+ descriptors). Suggested-by: Maciej Fijalkowski # static key Signed-off-by: Alexander Lobakin --- include/net/l

[Intel-wired-lan] [PATCH iwl-next 07/16] libeth: xdp: add XDPSQ cleanup timers

2025-04-15 Thread Alexander Lobakin
of the last send. The timer is triggered when finalizing the queue. As long as there is regular active traffic, the timer doesn't fire. Signed-off-by: Alexander Lobakin --- include/net/libeth/types.h | 21 - include/net/libeth/xdp.h| 57

[Intel-wired-lan] [PATCH iwl-next 04/16] libeth: xdp: add .ndo_xdp_xmit() helpers

2025-04-15 Thread Alexander Lobakin
n its headroom, assuming it has enough of it for an 8 (or 4) byte value. In addition to @prep and @xmit driver callbacks in XDP_TX, xmit also needs @finalize to kick the XDPSQ after filling. Signed-off-by: Alexander Lobakin --- include/net/libeth/tx.h | 6 + include/net/libeth/

[Intel-wired-lan] [PATCH iwl-next 05/16] libeth: xdp: add XDPSQE completion helpers

2025-04-15 Thread Alexander Lobakin
we don't need inlining but convenience. Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Makefile | 1 + include/net/libeth/types.h | 21 ++- drivers/net/ethernet/intel/libeth/priv.h | 26 + include/net/libeth/tx.h

[Intel-wired-lan] [PATCH iwl-next 03/16] libeth: xdp: add XDP_TX buffers sending

2025-04-15 Thread Alexander Lobakin
Suggested-by: Maciej Fijalkowski # xmit logic Signed-off-by: Alexander Lobakin --- drivers/net/ethernet/intel/libeth/Kconfig | 10 +- drivers/net/ethernet/intel/libeth/Makefile | 6 +- include/net/libeth/tx.h| 11 +- include/net/libeth/xdp.h

[Intel-wired-lan] [PATCH iwl-next 02/16] libeth: support native XDP and register memory model

2025-04-15 Thread Alexander Lobakin
ed-off-by: Alexander Lobakin --- include/net/libeth/rx.h| 6 +- drivers/net/ethernet/intel/libeth/rx.c | 20 +++- 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/include/net/libeth/rx.h b/include/net/libeth/rx.h index 7d5dc58984b1..5d99140484

[Intel-wired-lan] [PATCH iwl-next 01/16] libeth: convert to netmem

2025-04-15 Thread Alexander Lobakin
faster "unsafe" underscored netmem <--> virt accessors as netmem_is_net_iov() is always false in that case, but consumes some cycles (bit test + true branch). Misc: replace explicit EXPORT_SYMBOL_NS_GPL("NS") with DEFAULT_SYMBOL_NAMESPACE. Reviewed-by: Mina Almasry Signe

[Intel-wired-lan] [PATCH iwl-next 00/16] libeth: add libeth_xdp helper lib

2025-04-15 Thread Alexander Lobakin
sts here ("XDP for idpf"). Macros for building driver XDP functions lead to that some implementations (XDP_TX, ndo_xdp_xmit etc.) consist of really only a few lines. Alexander Lobakin (16): libeth: convert to netmem libeth: support native XDP and register memory model libeth: xdp

Re: [Intel-wired-lan] [PATCH net-next 14/16] idpf: add support for XDP on Rx

2025-04-10 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Tue, 11 Mar 2025 16:50:07 +0100 > On Wed, Mar 05, 2025 at 05:21:30PM +0100, Alexander Lobakin wrote: >> Use libeth XDP infra to support running XDP program on Rx polling. >> This includes all of the possible verdicts/actions. >> XDP Tx queue

Re: [Intel-wired-lan] [PATCH iwl-next 05/14] libeth: add control queue support

2025-04-10 Thread Alexander Lobakin
From: Leon Romanovsky Date: Thu, 10 Apr 2025 14:23:49 +0300 > On Thu, Apr 10, 2025 at 12:44:33PM +0200, Larysa Zaremba wrote: >> On Thu, Apr 10, 2025 at 11:21:37AM +0300, Leon Romanovsky wrote: >>> On Tue, Apr 08, 2025 at 02:47:51PM +0200, Larysa Zaremba wrote: From: Phani R Burra

Re: [Intel-wired-lan] [PATCH iwl-next 05/14] libeth: add control queue support

2025-04-10 Thread Alexander Lobakin
From: Leon Romanovsky Date: Thu, 10 Apr 2025 16:27:06 +0300 > On Thu, Apr 10, 2025 at 02:58:28PM +0200, Larysa Zaremba wrote: >> On Thu, Apr 10, 2025 at 02:23:49PM +0300, Leon Romanovsky wrote: >>> On Thu, Apr 10, 2025 at 12:44:33PM +0200, Larysa Zaremba wrote: On Thu, Apr 10, 2025 at 11:21:

Re: [Intel-wired-lan] [PATCH iwl-next 05/14] libeth: add control queue support

2025-04-10 Thread Alexander Lobakin
From: Leon Romanovsky Date: Thu, 10 Apr 2025 16:44:43 +0300 > On Thu, Apr 10, 2025 at 03:05:19PM +0200, Alexander Lobakin wrote: >> From: Leon Romanovsky >> Date: Thu, 10 Apr 2025 14:23:49 +0300 >> >>> On Thu, Apr 10, 2025 at 12:44:33PM +0200, Larysa Zaremba wrote

Re: [Intel-wired-lan] [PATCH iwl-next 05/14] libeth: add control queue support

2025-04-10 Thread Alexander Lobakin
From: Leon Romanovsky Date: Thu, 10 Apr 2025 16:58:43 +0300 > On Thu, Apr 10, 2025 at 03:33:40PM +0200, Alexander Lobakin wrote: >> From: Leon Romanovsky >> Date: Thu, 10 Apr 2025 16:27:06 +0300 >> >>> On Thu, Apr 10, 2025 at 02:58:28PM +0200, Larysa Zaremba wrote

Re: [Intel-wired-lan] [PATCH net-next 11/16] idpf: prepare structures to support XDP

2025-04-08 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Wed, 19 Mar 2025 17:29:37 +0100 > On Mon, Mar 17, 2025 at 03:50:11PM +0100, Alexander Lobakin wrote: >> From: Maciej Fijalkowski >> Date: Fri, 7 Mar 2025 14:27:13 +0100 >> >>> On Wed, Mar 05, 2025 at 05:21:27PM +0100, Alexander Lo

Re: [Intel-wired-lan] [PATCH net-next 03/16] libeth: add a couple of XDP helpers (libeth_xdp)

2025-04-08 Thread Alexander Lobakin
From: Alexander Lobakin Date: Tue, 8 Apr 2025 15:22:48 +0200 > From: Maciej Fijalkowski > Date: Tue, 11 Mar 2025 15:05:38 +0100 > >> On Wed, Mar 05, 2025 at 05:21:19PM +0100, Alexander Lobakin wrote: >>> "Couple" is a bit humbly... Add the

Re: [Intel-wired-lan] [PATCH net-next 03/16] libeth: add a couple of XDP helpers (libeth_xdp)

2025-04-08 Thread Alexander Lobakin
From: Alexander Lobakin Date: Tue, 1 Apr 2025 15:11:50 +0200 > From: Maciej Fijalkowski > Date: Wed, 19 Mar 2025 17:19:44 +0100 [...] >> Not sure what to say here. Your time dedicated for making this work easier >> to swallow means less time dedicated for going through th

Re: [Intel-wired-lan] [PATCH net-next 15/16] idpf: add support for .ndo_xdp_xmit()

2025-04-08 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Tue, 11 Mar 2025 17:08:22 +0100 > On Wed, Mar 05, 2025 at 05:21:31PM +0100, Alexander Lobakin wrote: >> Use libeth XDP infra to implement .ndo_xdp_xmit() in idpf. >> The Tx callbacks are reused from XDP_TX code. XDP redirect target >> f

Re: [Intel-wired-lan] [PATCH net-next 03/16] libeth: add a couple of XDP helpers (libeth_xdp)

2025-04-08 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Tue, 11 Mar 2025 15:05:38 +0100 > On Wed, Mar 05, 2025 at 05:21:19PM +0100, Alexander Lobakin wrote: >> "Couple" is a bit humbly... Add the following functionality to libeth: [...] >> +struct libeth_rq_napi_stats { >> +

Re: [Intel-wired-lan] [PATCH net-next 03/16] libeth: add a couple of XDP helpers (libeth_xdp)

2025-04-05 Thread Alexander Lobakin
From: Maciej Fijalkowski Date: Wed, 19 Mar 2025 17:19:44 +0100 > On Mon, Mar 17, 2025 at 04:26:04PM +0100, Alexander Lobakin wrote: >> From: Maciej Fijalkowski >> Date: Tue, 11 Mar 2025 15:05:38 +0100 >> >>> On Wed, Mar 05, 2025 at 05:21:19PM +0100, Alexander Lob

Re: [Intel-wired-lan] [PATCH iwl-next 2/2] idpf: add flow steering support

2025-03-26 Thread Alexander Lobakin
From: Ahmed Zaki Date: Mon, 24 Mar 2025 07:49:38 -0600 > Use the new virtchnl2 OP codes to communicate with the Control Plane to > add flow steering filters. We add the basic functionality for ADD/Delete > with TCP/UDP IPv4 only. Support for other OP codes and protocols will be > added later. >

Re: [Intel-wired-lan] [PATCH iwl-next 0/2] idpf: add flow steering support

2025-03-26 Thread Alexander Lobakin
From: Ahmed Zaki Date: Mon, 24 Mar 2025 07:49:36 -0600 > Add basic flow steering. For now, we support IPv4 and TCP/UDP only. 1. Very poor cover letter. I'd suggest describing a bit more here. 2. net-next is closed, so this is RFC at max. 3. I haven't seen this reviewed properly on our internal M

Re: [Intel-wired-lan] [PATCH net-next 07/16] idpf: link NAPIs to queues

2025-03-18 Thread Alexander Lobakin
From: Alexander Lobakin Date: Wed, 12 Mar 2025 18:16:11 +0100 > From: Eric Dumazet > Date: Fri, 7 Mar 2025 11:28:36 +0100 > >> On Wed, Mar 5, 2025 at 5:22 PM Alexander Lobakin >> wrote: >>> >>> Add the missing linking of NAPIs to netdev queues when ena

  1   2   3   4   5   6   >