Re: [RFC net-next 04/15] net: Let memory providers set RX buffer headroom
From: Stanislav Fomichev
Date: Mon Oct 05 2026 - 12:54:17 EST
On 10/02, Björn Töpel wrote:
> AF_XDP lets userspace choose a headroom in front of the packet data
> in each UMEM chunk, and the kernel adds XDP_PACKET_HEADROOM to it. A
> driver whose buffers come from an AF_XDP memory provider must put
> packets after this headroom. The driver sees only the page pool, so
> it has no generic way to learn the value, and nothing checks that
> the driver supports it.
>
> Add rx_headroom to the provider parameters and to the queue
> configuration. It is the full headroom, including
> XDP_PACKET_HEADROOM; zero means the driver default. Add
> QCFG_RX_HEADROOM. A provider that sets a headroom can only be
> installed on a queue that supports it; otherwise the install fails
> with -EOPNOTSUPP. The driver checks the value with the rest of the
> queue configuration.
>
> Signed-off-by: Björn Töpel <bjorn@xxxxxxxxxx>
This is also a bit confusing to read on its own. Do we not need to
convert existing users? The next patch does not seem to use this new rx_headroom?