tsnep: XDP socket zero-copy support
Status from this message: This series was applied to netdev/net-next.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest6 patches 0 repliesApplied 6/6
- v36 patches 12 repliesSuperseded
- v26 patches 4 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 5 patches | 8 replies | Superseded |
Changes in v4 from the cover letter
- move l2fwd ZC numbers to last commit (Maciej Fijalkowski)
- mention frame size of measurements (Maciej Fijalkowski)
- add NETDEV_XDP_ACT_XSK_ZEROCOPY flag with last commit (Maciej Fijalkowski)
Patches in v4 All 6 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | tsnep: Replace modulo operation with maskdrivers/ drivers/ | +15 | 0 replies | Applied |
| 2/6 | tsnep: Rework TX/RX queue initializationdrivers/ | +51 | 0 replies | Applied |
| 3/6 | tsnep: Add functions for queue enable/disabledrivers/ | +64 | 0 replies | Applied |
| 4/6 | tsnep: Move skb receive action to separate functiondrivers/ | +23 | 0 replies | Applied |
| 5/6 | tsnep: Add XDP socket zero-copy RX supportdrivers/ drivers/ drivers/ | +556 | 0 replies | Applied |
| 6/6 | tsnep: Add XDP socket zero-copy TX supportdrivers/ drivers/ | +121 | 0 replies | Applied |
Reviews trailers per patch
All 6 patches have a Reviewed-by or Acked-by.
| Patch | Maciej Fijalkowski |
|---|---|
| 1/6 | R-b |
| 2/6 | R-b |
| 3/6 | R-b |
| 4/6 | R-b |
| 5/6 | R-b |
| 6/6 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH net-next v4 0/6] tsnep: XDP socket zero-copy support
Implement XDP socket zero-copy support for tsnep driver. I tried to follow existing drivers like igc as far as possible. But one main difference is that tsnep does not need any reconfiguration for XDP BPF program setup. So I decided to keep this behavior no matter if a XSK pool is used or not. As a result, tsnep starts using the XSK pool even if no XDP BPF program is available.
Another difference is that I tried to prevent potentially failing allocations during XSK pool setup. E.g. both memory models for page pool and XSK pool are registered all the time. Thus, XSK pool setup cannot end up with not working queues.
Some prework is done to reduce the last two XSK commits to actual XSK changes.
v4:
- move l2fwd ZC numbers to last commit (Maciej Fijalkowski)
- mention frame size of measurements (Maciej Fijalkowski)
- add NETDEV_XDP_ACT_XSK_ZEROCOPY flag with last commit (Maciej Fijalkowski)
v3:
- use __netif_tx_lock_bh() (Paolo Abeni)
- comment that rx->page_buffer is always zero terminated (Paolo Abeni)
v2:
- eliminate modulo op in TX/RX path (Maciej Fijalkowski)
- eliminate retval variable in tsnep_rx_alloc_zc() (Maciej Fijalkowski)
- scope variable entry within loop (Maciej Fijalkowski)
- use DMA_ATTR_SKIP_CPU_SYNC directly (Maciej Fijalkowski)
- union for page/xdp in tsnep_rx_entry (Maciej Fijalkowski)
- provide performance numbers (Maciej Fijalkowski)
- use xsk_buff_alloc_batch() (Maciej Fijalkowski)
- use xsk_tx_peek_release_desc_batch() (Maciej Fijalkowski)
- don't call tsnep_rx_reopen() if netdev is down
- init adapter pointer of queue only once
Gerhard Engleder (6):
tsnep: Replace modulo operation with mask
tsnep: Rework TX/RX queue initialization
tsnep: Add functions for queue enable/disable
tsnep: Move skb receive action to separate function
tsnep: Add XDP socket zero-copy RX support
tsnep: Add XDP socket zero-copy TX support
drivers/net/ethernet/engleder/tsnep.h | 16 +- drivers/net/ethernet/engleder/tsnep_main.c | 863 ++++++++++++++++++--- drivers/net/ethernet/engleder/tsnep_xdp.c | 66 ++ 3 files changed, 822 insertions(+), 123 deletions(-)
Signature · 1 line
2.30.2