RFC Reduce code duplication across Intel NIC drivers
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest21 patches 11 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/21 | common/intel_eth: add pkt reassembly fn for intel driversdrivers/ drivers/ drivers/ +19 more | +123 | 0 replies | |
| 1/21 | net/_common_intel: add pkt reassembly fn for intel driversdrivers/ drivers/ drivers/ +19 more | +123 | 0 replies | |
| 2/21 | common/intel_eth: provide common Tx entry structuresdrivers/ drivers/ drivers/ +26 more | +107 | 0 replies | |
| 2/21 | net/_common_intel: provide common Tx entry structuresdrivers/ drivers/ drivers/ +26 more | +105 | 0 replies | |
| 3/21 | common/intel_eth: add Tx mbuf ring replenish fndrivers/ drivers/ drivers/ +9 more | +23 | 0 replies | |
| 3/21 | net/_common_intel: add Tx mbuf ring replenish fndrivers/ drivers/ drivers/ +9 more | +23 | 0 replies | |
| 4/21 | drivers/net: align Tx queue struct field namesdrivers/ drivers/ drivers/ +11 more | +114 | 0 replies | |
| 4/21 | drivers/net: align Tx queue struct field namesdrivers/ drivers/ drivers/ +11 more | +116 | 0 replies | |
| 5/21 | drivers/net: add prefix for driver-specific structsdrivers/ drivers/ drivers/ +26 more | +128 | 0 replies | |
| 5/21 | drivers/net: add prefix for driver-specific structsdrivers/ drivers/ drivers/ +26 more | +128 | 0 replies | |
| 6/21 | common/intel_eth: merge ice and i40e Tx queue structdrivers/ drivers/ drivers/ +21 more | +164 | 0 replies | |
| 6/21 | net/_common_intel: merge ice and i40e Tx queue structdrivers/ drivers/ drivers/ +21 more | +165 | 0 replies | |
| 7/21 | net/iavf: use common Tx queue structuredrivers/ drivers/ drivers/ +7 more | +63 | 0 replies | |
| 7/21 | net/iavf: use common Tx queue structuredrivers/ drivers/ drivers/ +7 more | +62 | 0 replies | |
| 8/21 | net/ixgbe: convert Tx queue context cache field to ptrdrivers/ drivers/ | +6 | 0 replies | |
| 8/21 | net/ixgbe: convert Tx queue context cache field to ptrdrivers/ drivers/ | +6 | 0 replies | |
| 9/21 | net/ixgbe: use common Tx queue structuredrivers/ drivers/ drivers/ +5 more | +68 | 0 replies | |
| 9/21 | net/ixgbe: use common Tx queue structuredrivers/ drivers/ drivers/ +5 more | +80 | 3 replies | |
| 10/21 | common/intel_eth: pack Tx queue structuredrivers/ drivers/ drivers/ | +11 | 0 replies | |
| 10/21 | net/_common_intel: pack Tx queue structuredrivers/ drivers/ drivers/ | +11 | 0 replies | |
| 11/21 | common/intel_eth: add post-Tx buffer free functiondrivers/ drivers/ drivers/ +1 more | +99 | 0 replies | |
| 11/21 | net/_common_intel: add post-Tx buffer free functiondrivers/ drivers/ drivers/ +1 more | +98 | 4 replies | |
| 12/21 | common/intel_eth: add Tx buffer free fn for AVX-512drivers/ drivers/ drivers/ | +95 | 0 replies | |
| 12/21 | net/_common_intel: add Tx buffer free fn for AVX-512drivers/ drivers/ drivers/ | +95 | 0 replies | |
| 13/21 | net/iavf: use common Tx free fn for AVX-512drivers/ drivers/ drivers/ +1 more | +7 | 0 replies | |
| 13/21 | net/iavf: use common Tx free fn for AVX-512drivers/ drivers/ drivers/ +1 more | +7 | 0 replies | |
| 14/21 | net/ice: move Tx queue mbuf cleanup fn to commondrivers/ drivers/ drivers/ +3 more | +61 | 0 replies | |
| 14/21 | net/ice: move Tx queue mbuf cleanup fn to commondrivers/ drivers/ drivers/ +3 more | +61 | 0 replies | |
| 15/21 | net/i40e: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ | +10 | 0 replies | |
| 15/21 | net/i40e: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ | +9 | 0 replies | |
| 16/21 | net/ixgbe: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ +2 more | +5 | 0 replies | |
| 16/21 | net/ixgbe: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ +2 more | +5 | 0 replies | |
| 17/21 | net/iavf: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ +6 more | +28 | 0 replies | |
| 17/21 | net/iavf: use common Tx queue mbuf cleanup fndrivers/ drivers/ drivers/ +6 more | +31 | 0 replies | |
| 18/21 | net/ice: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +3 more | +22 | 0 replies | |
| 18/21 | net/ice: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +3 more | +22 | 0 replies | |
| 19/21 | net/i40e: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +4 more | +31 | 0 replies | |
| 19/21 | net/i40e: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +4 more | +31 | 0 replies | |
| 20/21 | net/iavf: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +2 more | +13 | 0 replies | |
| 20/21 | net/iavf: use vector SW ring for all vector pathsdrivers/ drivers/ drivers/ +2 more | +13 | 0 replies | |
| 21/21 | net/ixgbe: use common Tx backlog entry fndrivers/ drivers/ drivers/ | +4 | 0 replies | |
| 21/21 | net/ixgbe: use common Tx backlog entry fndrivers/ drivers/ drivers/ | +4 | 0 replies |
Reviews trailers per patch
None of the 42 patches has a Reviewed-by or Acked-by.
| Patch | Praveen Shetty |
|---|---|
| Series | Series-Acked-by |
| 1/21 | |
| 1/21 | |
| 2/21 | |
| 2/21 | |
| 3/21 | |
| 3/21 | |
| 4/21 | |
| 4/21 | |
| 5/21 | |
| 5/21 | |
| 6/21 | |
| 6/21 | |
| 7/21 | |
| 7/21 | |
| 8/21 | |
| 8/21 | |
| 9/21 | |
| 9/21 | |
| 10/21 | |
| 10/21 | |
| 11/21 | |
| 11/21 | |
| 12/21 | |
| 12/21 | |
| 13/21 | |
| 13/21 | |
| 14/21 | |
| 14/21 | |
| 15/21 | |
| 15/21 | |
| 16/21 | |
| 16/21 | |
| 17/21 | |
| 17/21 | |
| 18/21 | |
| 18/21 | |
| 19/21 | |
| 19/21 | |
| 20/21 | |
| 20/21 | |
| 21/21 | |
| 21/21 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [RFC PATCH 00/21] Reduce code duplication across Intel NIC drivers
This RFC attempts to reduce the amount of code duplication across a number of Intel NIC drivers, specifically: ixgbe, i40e, iavf, and ice.
The first patch extract a function from the Rx side, otherwise the majority of the changes are on the Tx side, leading to a converged Tx queue structure across the 4 drivers, and a large number of common functions.
Open question:
* How should common code across drivers within a single device class be managed?
- For now, I've created an "intel_eth" folder within the "common" driver directory, thinking about it after, it implies to me that it is common across driver classes.
- Would it be better to create an "intel_common" directory within the "net" folder?
Bruce Richardson (21):
common/intel_eth: add pkt reassembly fn for intel drivers common/intel_eth: provide common Tx entry structures common/intel_eth: add Tx mbuf ring replenish fn drivers/net: align Tx queue struct field names drivers/net: add prefix for driver-specific structs common/intel_eth: merge ice and i40e Tx queue struct net/iavf: use common Tx queue structure net/ixgbe: convert Tx queue context cache field to ptr net/ixgbe: use common Tx queue structure common/intel_eth: pack Tx queue structure common/intel_eth: add post-Tx buffer free function common/intel_eth: add Tx buffer free fn for AVX-512 net/iavf: use common Tx free fn for AVX-512 net/ice: move Tx queue mbuf cleanup fn to common net/i40e: use common Tx queue mbuf cleanup fn net/ixgbe: use common Tx queue mbuf cleanup fn net/iavf: use common Tx queue mbuf cleanup fn net/ice: use vector SW ring for all vector paths net/i40e: use vector SW ring for all vector paths net/iavf: use vector SW ring for all vector paths net/ixgbe: use common Tx backlog entry fn
drivers/common/intel_eth/ieth_rxtx.h | 153 +++++++++++ .../common/intel_eth/ieth_rxtx_vec_common.h | 260 ++++++++++++++++++ drivers/net/i40e/i40e_ethdev.c | 4 +- drivers/net/i40e/i40e_ethdev.h | 8 +- drivers/net/i40e/i40e_fdir.c | 10 +- .../net/i40e/i40e_recycle_mbufs_vec_common.c | 6 +- drivers/net/i40e/i40e_rxtx.c | 194 +++++-------- drivers/net/i40e/i40e_rxtx.h | 61 +--- drivers/net/i40e/i40e_rxtx_vec_altivec.c | 26 +- drivers/net/i40e/i40e_rxtx_vec_avx2.c | 26 +- drivers/net/i40e/i40e_rxtx_vec_avx512.c | 144 +--------- drivers/net/i40e/i40e_rxtx_vec_common.h | 144 +--------- drivers/net/i40e/i40e_rxtx_vec_neon.c | 26 +- drivers/net/i40e/i40e_rxtx_vec_sse.c | 26 +- drivers/net/i40e/meson.build | 2 +- drivers/net/iavf/iavf.h | 2 +- drivers/net/iavf/iavf_ethdev.c | 4 +- drivers/net/iavf/iavf_rxtx.c | 180 +++++------- drivers/net/iavf/iavf_rxtx.h | 61 +--- drivers/net/iavf/iavf_rxtx_vec_avx2.c | 46 ++-- drivers/net/iavf/iavf_rxtx_vec_avx512.c | 213 +++----------- drivers/net/iavf/iavf_rxtx_vec_common.h | 160 +---------- drivers/net/iavf/iavf_rxtx_vec_sse.c | 57 ++-- drivers/net/iavf/iavf_vchnl.c | 6 +- drivers/net/iavf/meson.build | 2 +- drivers/net/ice/ice_dcf.c | 4 +- drivers/net/ice/ice_dcf_ethdev.c | 21 +- drivers/net/ice/ice_diagnose.c | 2 +- drivers/net/ice/ice_ethdev.c | 2 +- drivers/net/ice/ice_ethdev.h | 7 +- drivers/net/ice/ice_rxtx.c | 164 +++++------ drivers/net/ice/ice_rxtx.h | 52 +--- drivers/net/ice/ice_rxtx_vec_avx2.c | 26 +- drivers/net/ice/ice_rxtx_vec_avx512.c | 153 +---------- drivers/net/ice/ice_rxtx_vec_common.h | 190 +------------ drivers/net/ice/ice_rxtx_vec_sse.c | 30 +- drivers/net/ice/meson.build | 2 +- drivers/net/ixgbe/base/ixgbe_osdep.h | 2 +- drivers/net/ixgbe/ixgbe_ethdev.c | 4 +- .../ixgbe/ixgbe_recycle_mbufs_vec_common.c | 6 +- drivers/net/ixgbe/ixgbe_rxtx.c | 137 ++++----- drivers/net/ixgbe/ixgbe_rxtx.h | 73 +---- drivers/net/ixgbe/ixgbe_rxtx_vec_common.h | 119 +------- drivers/net/ixgbe/ixgbe_rxtx_vec_neon.c | 33 +-- drivers/net/ixgbe/ixgbe_rxtx_vec_sse.c | 33 +-- drivers/net/ixgbe/meson.build | 2 +- 46 files changed, 1008 insertions(+), 1875 deletions(-) create mode 100644 drivers/common/intel_eth/ieth_rxtx.h create mode 100644 drivers/common/intel_eth/ieth_rxtx_vec_common.h
--
2.43.0