Re: [PATCH net-next v2] net: bcmgenet: convert RX path to page_pool
From: Justin Chen
Date: Thu Jun 11 2026 - 13:13:59 EST
On 6/10/26 4:48 AM, Nicolai Buchwitz wrote:
Replace the per-packet __netdev_alloc_skb() + dma_map_single() in the
RX path with page_pool. SKBs are built from pool pages via
napi_build_skb() with skb_mark_for_recycle() so the network stack
returns pages to the pool, and DMA mapping happens once per page
instead of once per packet.
Reject HW-reported lengths smaller than the RSB so a runt cannot
underflow the SKB build path.
Drop the now-unused priv->rx_buf_len field and the rx_dma_failed soft
MIB counter (nothing increments it after the conversion). This
removes the "rx_dma_failed" entry from ethtool -S, which is a
user-visible change for monitoring tools that key on stat names.
Signed-off-by: Nicolai Buchwitz <nb@xxxxxxxxxxx>
Reviewed-by: Justin Chen <justin.chen@xxxxxxxxxxxx>
Tested-by: Justin Chen <justin.chen@xxxxxxxxxxxx>