mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH net-next v3 0/5] fbnic: Support larger RX pages
@ 2026-09-15 18:20 Björn Töpel
  2026-09-15 18:20 ` [PATCH net-next v3 1/5] net: Add netdev_config helpers Björn Töpel
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Björn Töpel @ 2026-09-15 18:20 UTC (permalink / raw)
  To: Alexander Duyck, Jakub Kicinski, kernel-team, Andrew Lunn,
	David S. Miller, Eric Dumazet, Paolo Abeni, Simon Horman,
	Shuah Khan, netdev, linux-kernel, linux-kselftest,
	Daniel Borkmann
  Cc: Björn Töpel, Mike Marciniszyn (Meta),
	Mohsin Bashir, Stanislav Fomichev, Bobby Eshleman,
	Dimitri Daskalakis, Weiming Shi, Maxime Chevallier, Jacob Keller,
	Breno Leitao, Tao Cui, Pavel Begunkov, David Wei

Hi!

This series adds support for large io_uring zero-copy RX buffers to
fbnic.

fbnic hardware consumes receive memory in 4 KiB device pages, while
io_uring may expose a larger software buffer, such as 256 KiB. Track
the device-page geometry per BDQ, represent each large buffer with
consecutive descriptors, and decode completions to the corresponding
offset within the buffer. HPQ keeps its existing PAGE_SIZE geometry.

Larger buffers also reduce pressure on the memory provider. One
provider allocation supplies multiple 4 KiB device pages, so the same
amount of receive memory needs fewer net_iov objects and fewer
allocation, refill, and recycle operations. Hardware descriptor use
remains unchanged.

Ring depth and buffer size must be validated together. An ethtool ring
change can otherwise make an active memory-provider configuration
invalid. Store accepted ring depths in netdev_config, stage proposed
values in cfg_pending, and validate the default and each RX queue
before committing the change. Both netlink and ioctl use the same
transaction helpers.

The selftest requests a power-of-two buffer larger than twice the MTU,
checks the reported buffer length, and verifies received data. It does
not assume how packets are placed within the buffer.

Sashiko found, as usual, a number of bugs. I've sent the relevant ones
to net.

Changes in v3
=============

- Carry Breno's Reviewed-by on the netdev_config helper patch.
- Clarify that the fbnic ring-depth consumer follows the core patch.
- Document initialization, override, normalization, and stored ring
  depth semantics.
- Drop the CQE placement assertion from the large-buffer test.
- Reject a zero RX-jumbo depth before validating large RX pages.
- Rebase on net-next.

Changes in v2
=============

- Add generic netdev_config lifecycle helpers for the netlink and ioctl
  paths.
- Store ring parameters in netdev_config and revalidate RX queues before
  committing a ring change.
- Preserve the distinction between accepted and applied HDS state.
- Track fbnic device-page geometry per BDQ.
- Validate the fbnic RX page size, fragment count, and PPQ depth.
- Add automated large-buffer test coverage.


v2: https://lore.kernel.org/netdev/20260910180908.1506533-1-bjorn@kernel.org/
v1: https://lore.kernel.org/netdev/20260522113225.241337-1-bjorn@kernel.org/

Björn Töpel (4):
  fbnic: Track BDQ device-page geometry per ring
  net: Revalidate queue config for ringparam changes
  fbnic: Support larger memory-provider RX pages
  selftests: drv-net: Request larger zcrx buffers

Jakub Kicinski (1):
  net: Add netdev_config helpers

 drivers/net/ethernet/meta/fbnic/fbnic_csr.h   |  34 +---
 .../net/ethernet/meta/fbnic/fbnic_debugfs.c   |   5 +-
 .../net/ethernet/meta/fbnic/fbnic_netdev.c    |   5 +
 drivers/net/ethernet/meta/fbnic/fbnic_txrx.c  | 173 ++++++++++++++----
 drivers/net/ethernet/meta/fbnic/fbnic_txrx.h  |   7 +
 include/net/netdev_queues.h                   |  49 ++++-
 net/core/dev.c                                |   7 +-
 net/core/dev.h                                |   7 +
 net/core/netdev_config.c                      |  75 +++++++-
 net/ethtool/common.c                          |   9 +
 net/ethtool/common.h                          |   2 +
 net/ethtool/ioctl.c                           |  24 ++-
 net/ethtool/netlink.c                         |  15 +-
 net/ethtool/rings.c                           |  13 +-
 .../selftests/drivers/net/hw/iou-zcrx.py      |   6 +-
 15 files changed, 345 insertions(+), 86 deletions(-)


base-commit: b8e9e7d82e7eefd5d2d528469d94ec20e96b38c3
-- 
2.55.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-09-16 14:58 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-15 18:20 [PATCH net-next v3 0/5] fbnic: Support larger RX pages Björn Töpel
2026-09-15 18:20 ` [PATCH net-next v3 1/5] net: Add netdev_config helpers Björn Töpel
2026-09-15 18:21 ` [PATCH net-next v3 2/5] fbnic: Track BDQ device-page geometry per ring Björn Töpel
2026-09-16 14:57   ` Breno Leitao
2026-09-15 18:21 ` [PATCH net-next v3 3/5] net: Revalidate queue config for ringparam changes Björn Töpel
2026-09-15 18:21 ` [PATCH net-next v3 4/5] fbnic: Support larger memory-provider RX pages Björn Töpel
2026-09-15 18:21 ` [PATCH net-next v3 5/5] selftests: drv-net: Request larger zcrx buffers Björn Töpel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®