libeth: support different types of buffers for Rx
authorAlexander Lobakin <aleksander.lobakin@intel.com>
Thu, 20 Jun 2024 13:53:45 +0000 (15:53 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Wed, 10 Jul 2024 17:46:32 +0000 (10:46 -0700)
commit5aaac1aece4e4db9d620791a33f7a4173c660e65
tree414715face75d3ad9a123940103d2f3425a602d6
parent4309363f19598999b25a1e55fccf688daa4cc220
libeth: support different types of buffers for Rx

Unlike previous generations, idpf requires more buffer types for optimal
performance. This includes: header buffers, short buffers, and
no-overhead buffers (w/o headroom and tailroom, for TCP zerocopy when
the header split is enabled).
Introduce libeth Rx buffer type and calculate page_pool params
accordingly. All the HW-related details like buffer alignment are still
accounted. For the header buffers, pick 256 bytes as in most places in
the kernel (have you ever seen frames with bigger headers?).

Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Signed-off-by: Alexander Lobakin <aleksander.lobakin@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/libeth/rx.c
include/net/libeth/rx.h