ethdev: isolate legacy flow director
Subsystems (3)
cover ethdev: isolate legacy flow director
The original flow support in DPDK was Intel specific and built around the flow director feature. It was superseded by the generic rte_flow API, and the legacy filter API was deprecated in 17.02 and removed in 20.11. What survived that removal are the data structures: they were never deleted, only relocated, and they remain wired into ethdev's public headers.
The visible cost is include pollution. Because rte_ethdev.h pulls in rte_eth_ctrl.h, which pulls in rte_flow.h, every application including rte_ethdev.h also gets rte_ether.h, rte_ip.h, rte_tcp.h, rte_udp.h and rte_sctp.h. A number of drivers and libraries have come to depend on that, without saying so.
This series breaks that chain.
01-02 Remove an unused include, and drop the last use of ntohl()
in ethdev in favour of the rte_byteorder macros.
03-04 Remove the flow director private APIs from ixgbe and i40e.
These are experimental, so no deprecation notice is required.
05 Remove flow director support from testpmd. The testpmd CLI
is not a stable interface, but "show port fdir" disappearing is user visible, so it is called out in the release notes.
06-19 Include hygiene. Each of these adds the network protocol
headers that a driver, library, test or example was getting indirectly. No functional change; each patch stands alone and can be acked by its maintainer without reading the rest of the series.
20 Move the remaining legacy definitions out of rte_eth_ctrl.h
and ethdev_driver.h into a single lib/ethdev/ethdev_fdir.h, included only by the drivers that need it, and drop the include from rte_ethdev.h.
21 Release notes.
ethdev_fdir.h is a transitional home, not a new interface. It is a driver SDK header, is not part of the public API, and exists only so that the drivers still carrying legacy flow director state have somewhere to get these definitions. New drivers should not use it. The intent is to delete it once ixgbe and i40e no longer need it.
This does not touch RTE_ETH_FLOW_* in rte_ethdev.h, which has users beyond flow director, nor the flow director state still held inside individual drivers.
Applications that were relying on the indirect includes will need to add explicit ones; this is a source level change only, with no ABI impact.
Build tested on x86_64 and aarch64, gcc and clang, with -Dexamples=all -Dtests=true -Denable_driver_sdk=true.
There is still more to do here but since I don't have Intel hardware and there is no standalone tests for this stuff will stick to mechanical refactoring.
Stephen Hemminger (21):
net/dpaa, net/dpaa2: remove unused include
ethdev: use byte order instead of ntohl net/ixgbe: remove experimental FDIR API net/i40e: remove experimental FDIR API app/testpmd: remove support for flow director net/gve: include IP, UDP and TCP header crypto/dpaa_sec: include UDP header net/nfp: break implicit dependency on rte_eth_ctrl.h net/mana: include used network headers
gro: include headers directly
test: include headers directly
node: get UDP header
net/rnp: include network headers
net/r8169: get network headers
net/ngbe: include network protocol headers
examples: include network headers
net/mlx5: include rte_flow as needed net/sfc: include rte_flow
net/intel: include network headers
ethdev, drivers: isolate flow director
doc: add release not about rte_ethdev changes
app/test-eventdev/test_pipeline_common.h | 1 +
app/test-pmd/cmdline.c | 21 +--
app/test-pmd/config.c | 163 ------------------
app/test-pmd/testpmd.h | 3 -
app/test/test_bpf.c | 3 +
app/test/test_security_inline_macsec.c | 2 +
app/test/test_security_inline_proto.c | 1 +
doc/api/doxy-api-index.md | 1 -
doc/guides/rel_notes/release_26_11.rst | 13 ++
doc/guides/testpmd_app_ug/testpmd_funcs.rst | 36 ----
drivers/crypto/dpaa_sec/dpaa_sec.h | 2 +
drivers/net/dpaa/dpaa_ptp.c | 1 -
drivers/net/dpaa2/dpaa2_ptp.c | 1 -
drivers/net/gve/gve_ethdev.h | 3 +
drivers/net/hinic/hinic_pmd_ethdev.h | 2 +
drivers/net/hinic3/hinic3_ethdev.h | 1 +
drivers/net/intel/common/tx_scalar.h | 3 +
drivers/net/intel/cpfl/cpfl_flow_engine_fxp.c | 2 +-
drivers/net/intel/e1000/e1000_ethdev.h | 1 +
drivers/net/intel/e1000/igc_filter.h | 2 +-
drivers/net/intel/i40e/i40e_ethdev.c | 4 +-
drivers/net/intel/i40e/i40e_ethdev.h | 5 +-
drivers/net/intel/i40e/i40e_fdir.c | 140 ---------------
drivers/net/intel/i40e/i40e_flow.c | 3 +-
drivers/net/intel/i40e/rte_pmd_i40e.c | 34 ----
drivers/net/intel/i40e/rte_pmd_i40e.h | 33 ----
drivers/net/intel/iavf/iavf_fsub.c | 2 +-
drivers/net/intel/iavf/iavf_hash.c | 2 +-
drivers/net/intel/ice/ice_acl_filter.c | 2 +-
drivers/net/intel/ice/ice_ethdev.h | 2 +
drivers/net/intel/ice/ice_generic_flow.c | 1 +
drivers/net/intel/ice/ice_hash.c | 2 +-
drivers/net/intel/ice/ice_switch_filter.c | 2 +-
drivers/net/intel/ipn3ke/ipn3ke_flow.c | 2 +-
drivers/net/intel/ixgbe/ixgbe_ethdev.h | 6 +-
drivers/net/intel/ixgbe/ixgbe_fdir.c | 117 -------------
drivers/net/intel/ixgbe/rte_pmd_ixgbe.c | 34 ----
drivers/net/intel/ixgbe/rte_pmd_ixgbe.h | 32 ----
drivers/net/mana/mana.c | 2 +
drivers/net/mana/tx.c | 3 +
drivers/net/mlx5/mlx5_ethdev.c | 1 +
drivers/net/mlx5/mlx5_flow.h | 1 +
drivers/net/mlx5/mlx5_txq.c | 1 +
drivers/net/mlx5/mlx5_utils.c | 1 +
drivers/net/mlx5/mlx5_utils.h | 1 +
drivers/net/nbl/nbl_include/nbl_include.h | 1 +
drivers/net/nfp/nfp_ethdev.c | 6 +-
drivers/net/nfp/nfp_net_common.h | 1 +
drivers/net/ngbe/ngbe_rxtx.c | 4 +
drivers/net/r8169/r8169_rxtx.c | 3 +
drivers/net/rnp/rnp_rxtx.c | 6 +
drivers/net/sfc/sfc_dp.c | 1 +
drivers/net/txgbe/txgbe_ethdev.h | 1 +
examples/l2fwd-macsec/main.c | 2 +
examples/l3fwd-graph/main.c | 1 +
examples/l3fwd/l3fwd.h | 2 +
lib/ethdev/ethdev_driver.h | 36 ----
lib/ethdev/{rte_eth_ctrl.h => ethdev_fdir.h} | 58 +++++--
lib/ethdev/meson.build | 2 +-
lib/ethdev/rte_ethdev.h | 13 +-
lib/ethdev/sff_8472.c | 3 +-
lib/gro/gro_tcp4.c | 1 +
lib/gro/gro_vxlan_tcp4.c | 4 +-
lib/gro/gro_vxlan_udp4.c | 1 +
lib/gro/rte_gro.c | 1 +
lib/node/udp4_input.c | 1 +
66 files changed, 147 insertions(+), 696 deletions(-)
rename lib/ethdev/{rte_eth_ctrl.h => ethdev_fdir.h} (91%)Signature · 1 line
2.53.0
RFC 1/21 net/dpaa, net/dpaa2: remove unused include
rte_eth_ctrl.h is not needed.
--- drivers/net/dpaa/dpaa_ptp.c | 1 - drivers/net/dpaa2/dpaa2_ptp.c | 1 - 2 files changed, 2 deletions(-)
drivers/net/dpaa/dpaa_ptp.c +0 -1
@@ -9,7 +9,6 @@#include <rte_ethdev.h> #include <rte_log.h> -#include <rte_eth_ctrl.h> #include <rte_malloc.h> #include <rte_time.h>
drivers/net/dpaa2/dpaa2_ptp.c +0 -1
@@ -12,7 +12,6 @@#include <ethdev_driver.h> #include <rte_log.h> -#include <rte_eth_ctrl.h> #include <rte_malloc.h> #include <rte_time.h>
Signature · 1 line
2.53.0
RFC 2/21 ethdev: use byte order instead of ntohl
In reply to Stephen HemmingerDPDK has its own byte order macros which are preferred over the Linux ones in arpa/inet.h
--- lib/ethdev/sff_8472.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
lib/ethdev/sff_8472.c +2 -1
@@ -4,6 +4,7 @@*/ #include <stdio.h> +#include <rte_byteorder.h> #include "sff_common.h"
@@ -176,7 +177,7 @@ static float befloattoh(const uint32_t *source)float dst; } converter; - converter.src =ntohl (*source); + converter.src =rte_be_to_cpu_32 (*source);return converter.dst; }
Signature · 1 line
2.53.0
RFC 3/21 net/ixgbe: remove experimental FDIR API
In reply to Stephen HemmingerRemove the flow director related private APIs in ixgbe.
These APIs are experimental therefore they can be removed without deprecation warning.
--- drivers/net/intel/ixgbe/ixgbe_ethdev.h | 5 - drivers/net/intel/ixgbe/ixgbe_fdir.c | 117 ------------------------ drivers/net/intel/ixgbe/rte_pmd_ixgbe.c | 34 ------- drivers/net/intel/ixgbe/rte_pmd_ixgbe.h | 32 ------- 4 files changed, 188 deletions(-)
drivers/net/intel/ixgbe/ixgbe_ethdev.h +0 -5
@@ -717,11 +717,6 @@ int ixgbe_fdir_filter_program(struct ixgbe_adapter *adapter,struct rte_eth_fdir_conf *fdir_conf, struct ixgbe_fdir_rule *rule, bool del, bool update); -void ixgbe_fdir_info_get (struct rte_eth_dev *dev, -struct rte_eth_fdir_info *fdir_info); -void ixgbe_fdir_stats_get (struct rte_eth_dev *dev, -struct rte_eth_fdir_stats *fdir_stats); -void ixgbe_configure_dcb (struct rte_eth_dev *dev);int
drivers/net/intel/ixgbe/ixgbe_fdir.c +0 -117
123 lines not on this page · raw message
drivers/net/intel/ixgbe/rte_pmd_ixgbe.c +0 -34
@@ -1176,37 +1176,3 @@ rte_pmd_ixgbe_mdio_unlocked_write(uint16_t port, uint32_t reg_addr,return 0 ; } -RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_pmd_ixgbe_get_fdir_info, 20.08) -int -rte_pmd_ixgbe_get_fdir_info (uint16_t port,struct rte_eth_fdir_info *fdir_info) -{ -struct rte_eth_dev *dev; - -RTE_ETH_VALID_PORTID_OR_ERR_RET (port, -ENODEV ); - - dev = &rte_eth_devices[port]; -if (!is_ixgbe_supported (dev)) -return -ENOTSUP ; - -ixgbe_fdir_info_get (dev, fdir_info); - -return 0 ; -} - -RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_pmd_ixgbe_get_fdir_stats, 20.08) -int -rte_pmd_ixgbe_get_fdir_stats (uint16_t port, -struct rte_eth_fdir_stats *fdir_stats) -{ -struct rte_eth_dev *dev; - -RTE_ETH_VALID_PORTID_OR_ERR_RET (port, -ENODEV ); - - dev = &rte_eth_devices[port]; -if (!is_ixgbe_supported (dev)) -return -ENOTSUP ; - -ixgbe_fdir_stats_get (dev, fdir_stats); - -return 0 ; -}
drivers/net/intel/ixgbe/rte_pmd_ixgbe.h +0 -32
@@ -724,36 +724,4 @@ enum {int rte_pmd_ixgbe_upd_fctrl_sbp (uint16_t port,int enable); -/** -* Get port fdir info -* -* @param port -* The port identifier of the Ethernet device. -* @param fdir_info -* The fdir info of the port -* @return -* - (0) if successful. -* - (-ENODEV) if *port* invalid. -* - (-ENOTSUP) if operation not supported. -*/ -__rte_experimental -int -rte_pmd_ixgbe_get_fdir_info (uint16_t port,struct rte_eth_fdir_info *fdir_info); - -/** -* Get port fdir status -* -* @param port -* The port identifier of the Ethernet device. -* @param fdir_stats -* The fdir status of the port -* @return -* - (0) if successful. -* - (-ENODEV) if *port* invalid. -* - (-ENOTSUP) if operation not supported. -*/ -__rte_experimental -int -rte_pmd_ixgbe_get_fdir_stats (uint16_t port, -struct rte_eth_fdir_stats *fdir_stats);#endif /* _PMD_IXGBE_H_ */
Signature · 1 line
2.53.0
RFC 4/21 net/i40e: remove experimental FDIR API
In reply to Stephen HemmingerRemove the flow director related private APIs in i40e.
These APIs are experimental, therefore they can be removed without deprecation warning.
--- drivers/net/intel/i40e/i40e_ethdev.c | 4 +- drivers/net/intel/i40e/i40e_ethdev.h | 4 - drivers/net/intel/i40e/i40e_fdir.c | 140 -------------------------- drivers/net/intel/i40e/i40e_flow.c | 3 +- drivers/net/intel/i40e/rte_pmd_i40e.c | 34 ------- drivers/net/intel/i40e/rte_pmd_i40e.h | 33 ------ 6 files changed, 3 insertions(+), 215 deletions(-)
drivers/net/intel/i40e/i40e_ethdev.c +2 -2
@@ -9335,8 +9335,8 @@ i40e_get_valid_input_set(enum i40e_filter_pctype pctype, };/** -* Flow director supports only fields defined in -* union rte_eth_fdir_flow. +* Flow director supports only fields reachable through +* rte_flow item patterns. */ static const uint64_t valid_fdir_inset_table[] = { [I40E_FILTER_PCTYPE_FRAG_IPV4] =
drivers/net/intel/i40e/i40e_ethdev.h +0 -4
@@ -1369,10 +1369,6 @@ enum i40e_filter_pctypeuint16_t i40e_pctype_to_flowtype (const struct i40e_adapter *adapter,enum i40e_filter_pctype pctype);int i40e_dev_set_gre_key_len (struct i40e_hw *hw,uint8_t len); -void i40e_fdir_info_get (struct rte_eth_dev *dev, -struct rte_eth_fdir_info *fdir); -void i40e_fdir_stats_get (struct rte_eth_dev *dev, -struct rte_eth_fdir_stats *stat);int i40e_select_filter_input_set (struct i40e_hw *hw,struct rte_eth_input_set_conf *conf,enum rte_filter_type filter);
drivers/net/intel/i40e/i40e_fdir.c +0 -140
146 lines not on this page · raw message
drivers/net/intel/i40e/i40e_flow.c +1 -2
@@ -2391,8 +2391,7 @@ i40e_flow_parse_fdir_pattern(struct rte_eth_dev *dev,for (i =0 ; i < raw_spec->length; i++) { j = i + next_dst_off; -if (j >=RTE_ETH_FDIR_MAX_FLEXLEN || - j >=I40E_FDIR_MAX_FLEX_LEN ) +if (j >=I40E_FDIR_MAX_FLEX_LEN )break ; filter->input.flow_ext.flexbytes[j] = raw_spec->pattern[i];
drivers/net/intel/i40e/rte_pmd_i40e.c +0 -34
@@ -3219,40 +3219,6 @@ rte_pmd_i40e_inset_set(uint16_t port, uint8_t pctype,return 0 ; } -RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_pmd_i40e_get_fdir_info, 20.08) -int -rte_pmd_i40e_get_fdir_info (uint16_t port,struct rte_eth_fdir_info *fdir_info) -{ -struct rte_eth_dev *dev; - -RTE_ETH_VALID_PORTID_OR_ERR_RET (port, -ENODEV ); - - dev = &rte_eth_devices[port]; -if (!is_i40e_supported (dev)) -return -ENOTSUP ; - -i40e_fdir_info_get (dev, fdir_info); - -return 0 ; -} - -RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_pmd_i40e_get_fdir_stats, 20.08) -int -rte_pmd_i40e_get_fdir_stats (uint16_t port,struct rte_eth_fdir_stats *fdir_stat) -{ -struct rte_eth_dev *dev; - -RTE_ETH_VALID_PORTID_OR_ERR_RET (port, -ENODEV ); - - dev = &rte_eth_devices[port]; -if (!is_i40e_supported (dev)) -return -ENOTSUP ; - -i40e_fdir_stats_get (dev, fdir_stat); - -return 0 ; -} - RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_pmd_i40e_set_gre_key_len, 20.08)int rte_pmd_i40e_set_gre_key_len (uint16_t port,uint8_t len)
drivers/net/intel/i40e/rte_pmd_i40e.h +0 -33
@@ -1067,39 +1067,6 @@ rte_pmd_i40e_inset_field_clear(uint64_t *inset, uint8_t field_idx)return 0 ; } -/** -* Get port fdir info -* -* @param port -* The port identifier of the Ethernet device. -* @param fdir_info -* The fdir info of the port -* @return -* - (0) if successful. -* - (-ENODEV) if *port* invalid. -* - (-ENOTSUP) if operation not supported. -*/ -__rte_experimental -int -rte_pmd_i40e_get_fdir_info (uint16_t port,struct rte_eth_fdir_info *fdir_info); - -/** -* Get port fdir status -* -* @param port -* The port identifier of the Ethernet device. -* @param fdir_stat -* The fdir status of the port -* @return -* - (0) if successful. -* - (-ENODEV) if *port* invalid. -* - (-ENOTSUP) if operation not supported. -*/ -__rte_experimental -int -rte_pmd_i40e_get_fdir_stats (uint16_t port, -struct rte_eth_fdir_stats *fdir_stat); -/** * Set GRE key length *
Signature · 1 line
2.53.0
RFC 5/21 app/testpmd: remove support for flow director
In reply to Stephen HemmingerThe flow director API is deprecated and will be removed in 26.11. Remove it from testpmd now since testpmd CLI is not a stable API.
--- app/test-pmd/cmdline.c | 21 +-- app/test-pmd/config.c | 163 -------------------- app/test-pmd/testpmd.h | 3 - doc/guides/testpmd_app_ug/testpmd_funcs.rst | 36 ----- 4 files changed, 6 insertions(+), 217 deletions(-)
app/test-pmd/cmdline.c +6 -15
@@ -163,7 +163,7 @@ static void cmd_help_long_parsed(void *parsed_result,"Display:\n" "--------\n\n" -"show port (info|stats|summary|xstats|fdir|dcb_tc) (port_id|all)\n" +"show port (info|stats|summary|xstats|dcb_tc) (port_id|all)\n" " Display information for port_id, or all.\n\n" "show port info (port_id) representor\n"
@@ -189,7 +189,7 @@ static void cmd_help_long_parsed(void *parsed_result,"show port (port_id) rss-hash [key | algorithm]\n" " Display the RSS hash functions, RSS hash key and RSS hash algorithms of port\n\n" -"clear port (info|stats|xstats|fdir) (port_id|all)\n" +"clear port (info|stats|xstats) (port_id|all)\n" " Clear information for port_id, or all.\n\n" "show (rxq|txq) info (port_id) (queue_id)\n"
@@ -7514,11 +7514,6 @@ static void cmd_showportall_parsed(void *parsed_result,else if (!strcmp (res->what,"xstats" )) RTE_ETH_FOREACH_DEV(i)nic_xstats_display (i); -#if defined(RTE_NET_I40E ) || defined(RTE_NET_IXGBE ) - else if (!strcmp(res->what, "fdir")) -RTE_ETH_FOREACH_DEV (i) -fdir_get_infos (i); -#endif else if (!strcmp (res->what,"dcb_tc" )) RTE_ETH_FOREACH_DEV(i)port_dcb_info_display (i);
@@ -7531,14 +7526,14 @@ static cmdline_parse_token_string_t cmd_showportall_port = TOKEN_STRING_INITIALIZER(struct cmd_showportall_result, port, "port");static cmdline_parse_token_string_t cmd_showportall_what = TOKEN_STRING_INITIALIZER(struct cmd_showportall_result, what, -"info#summary#stats#xstats#fdir#dcb_tc" ); +"info#summary#stats#xstats#dcb_tc" );static cmdline_parse_token_string_t cmd_showportall_all = TOKEN_STRING_INITIALIZER(struct cmd_showportall_result, all, "all");static cmdline_parse_inst_t cmd_showportall = { .f = cmd_showportall_parsed, .data =NULL , .help_str ="show|clear port " -"info|summary|stats|xstats|fdir|dcb_tc all" , +"info|summary|stats|xstats|dcb_tc all" , .tokens = { (void *)&cmd_showportall_show, (void *)&cmd_showportall_port,
@@ -7576,10 +7571,6 @@ static void cmd_showport_parsed(void *parsed_result,nic_stats_display (res->portnum); else if (!strcmp(res->what, "xstats"))nic_xstats_display (res->portnum); -#if defined(RTE_NET_I40E ) || defined(RTE_NET_IXGBE ) - else if (!strcmp(res->what, "fdir")) -fdir_get_infos (res->portnum); -#endif else if (!strcmp(res->what, "dcb_tc"))port_dcb_info_display (res->portnum); }
@@ -7591,7 +7582,7 @@ static cmdline_parse_token_string_t cmd_showport_port = TOKEN_STRING_INITIALIZER(struct cmd_showport_result, port, "port");static cmdline_parse_token_string_t cmd_showport_what = TOKEN_STRING_INITIALIZER(struct cmd_showport_result, what, -"info#summary#stats#xstats#fdir#dcb_tc" ); +"info#summary#stats#xstats#dcb_tc" );static cmdline_parse_token_num_t cmd_showport_portnum = TOKEN_NUM_INITIALIZER(struct cmd_showport_result, portnum, RTE_UINT16);
@@ -7599,7 +7590,7 @@ static cmdline_parse_inst_t cmd_showport = { .f = cmd_showport_parsed, .data = NULL, .help_str = "show|clear port " - "info|summary|stats|xstats|fdir|dcb_tc " + "info|summary|stats|xstats|dcb_tc " "<port_id>", .tokens = { (void *)&cmd_showport_show,
app/test-pmd/config.c +0 -163
169 lines not on this page · raw message
app/test-pmd/testpmd.h +0 -3
@@ -1212,9 +1212,6 @@ int all_ports_stopped(void);int port_is_stopped (portid_t port_id);int port_is_started (portid_t port_id);void pmd_test_exit (void ); -#if defined(RTE_NET_I40E ) || defined(RTE_NET_IXGBE ) -void fdir_get_infos (portid_t port_id); -#endif void port_rss_reta_info (portid_t port_id,struct rte_eth_rss_reta_entry64 *reta_conf,uint16_t nb_entries);
doc/guides/testpmd_app_ug/testpmd_funcs.rst +0 -36
@@ -2288,42 +2288,6 @@ Where the threshold type can be: These threshold options are also available from the command-line. -port config pctype mapping -~~~~~~~~~~~~~~~~~~~~~~~~~~ - -Reset pctype mapping table:: - - testpmd> port config (port_id) pctype mapping reset - -Update hardware defined pctype to software defined flow type mapping table:: - - testpmd> port config (port_id) pctype mapping update (pctype_id_0[,pctype_id_1]*) (flow_type_id) - -where: - -* ``pctype_id_x``: hardware pctype id as index of bit in bitmask value of the pctype mapping table. - -* ``flow_type_id``: software flow type id as the index of the pctype mapping table. - -port config input set -~~~~~~~~~~~~~~~~~~~~~ - -Config RSS/FDIR/FDIR flexible payload input set for some pctype:: - - testpmd> port config (port_id) pctype (pctype_id) \ - (hash_inset|fdir_inset|fdir_flx_inset) \ - (get|set|clear) field (field_idx) - -Clear RSS/FDIR/FDIR flexible payload input set for some pctype:: - - testpmd> port config (port_id) pctype (pctype_id) \ - (hash_inset|fdir_inset|fdir_flx_inset) clear all - -where: - -* ``pctype_id``: hardware packet classification types. -* ``field_idx``: hardware field index. - port config udp_tunnel_port ~~~~~~~~~~~~~~~~~~~~~~~~~~~
Signature · 1 line
2.53.0
RFC 6/21 net/gve: include IP, UDP and TCP header
In reply to Stephen HemmingerThis driver was getting rte_ip.h, rte_udp.h and rte_tcp.h implicitly through rte_ethdev.h -> rte_eth_ctrl.h -> rte_flow.h. Since rte_eth_ctrl.h is deprecated, better to not depend on that.
--- drivers/net/gve/gve_ethdev.h | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/gve/gve_ethdev.h +3 -0
@@ -14,6 +14,9 @@#include <rte_bitmap.h> #include <rte_memzone.h> #include <rte_thread.h> +#include <rte_udp.h> +#include <rte_tcp.h> +#include <rte_sctp.h> #include "base/gve.h"
Signature · 1 line
2.53.0
RFC 7/21 crypto/dpaa_sec: include UDP header
In reply to Stephen HemmingerDriver was getting udp header from headers included from rte_ethdev.h. That will change so include the used header directly.
--- drivers/crypto/dpaa_sec/dpaa_sec.h | 2 ++ 1 file changed, 2 insertions(+)
drivers/crypto/dpaa_sec/dpaa_sec.h +2 -0
@@ -7,6 +7,8 @@#ifndef _DPAA_SEC_H_#define _DPAA_SEC_H_ +#include <rte_udp.h> +#define CRYPTODEV_NAME_DPAA_SEC_PMD crypto_dpaa_sec/**< NXP DPAA - SEC PMD device name */
Signature · 1 line
2.53.0
RFC 8/21 net/nfp: break implicit dependency on rte_eth_ctrl.h
In reply to Stephen HemmingerThis driver was using UINT64_BIT which was getting defined via deprecated rte_eth_ctrl.h. Replace with local definition.
Also include rte_flow.h instead of depending on indirect inclusion from rte_ethdev.h.
--- drivers/net/nfp/nfp_ethdev.c | 6 ++++-- drivers/net/nfp/nfp_net_common.h | 1 + 2 files changed, 5 insertions(+), 2 deletions(-)
drivers/net/nfp/nfp_ethdev.c +4 -2
@@ -6,6 +6,7 @@*/ #include <unistd.h> +#include <limits.h> #include <eal_firmware.h> #include <rte_alarm.h>
@@ -32,6 +33,7 @@/* 64-bit per app capabilities */ #define NFP_NET_APP_CAP_SP_INDIFF RTE_BIT64(0)/* Indifferent to port speed */ +#define NFP_UINT64_BIT (CHAR_BIT * sizeof(uint64_t))#define NFP_PF_DRIVER_NAME net_nfp_pf#define NFP_PF_FORCE_RELOAD_FW "force_reload_fw"
@@ -2060,8 +2062,8 @@ nfp_net_speed_capa_get_real(struct nfp_eth_media_buf *media_buf,for (i =0 ; i <RTE_DIM (media_buf->supported_modes); i++) { supported_modes = media_buf->supported_modes[i]; - offset = i *UINT64_BIT ; -for (j =0 ; j <UINT64_BIT ; j++) { + offset = i *NFP_UINT64_BIT ; +for (j =0 ; j <NFP_UINT64_BIT ; j++) {if (supported_modes ==0 )break ;
drivers/net/nfp/nfp_net_common.h +1 -0
@@ -8,6 +8,7 @@#include <bus_pci_driver.h> #include <ethdev_driver.h> +#include <rte_flow.h> #include <nfp_common.h> #include <nfp_dev.h> #include <rte_spinlock.h>
Signature · 1 line
2.53.0
RFC 9/21 net/mana: include used network headers
In reply to Stephen HemmingerThis driver was getting definition of ip, udp, and tcp headers implicitly via rte_ethdev.h. That will be changing so instead include the required headers directly.
--- drivers/net/mana/mana.c | 2 ++ drivers/net/mana/tx.c | 3 +++ 2 files changed, 5 insertions(+)
drivers/net/mana/mana.c +2 -0
@@ -6,8 +6,10 @@#include <dirent.h> #include <fcntl.h> #include <sys/mman.h> +#include <sys/socket.h> #include <sys/ioctl.h> #include <net/if.h> +#include <netinet/in.h> #include <ethdev_driver.h> #include <ethdev_pci.h>
drivers/net/mana/tx.c +3 -0
@@ -3,6 +3,9 @@*/ #include <ethdev_driver.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> #include <infiniband/verbs.h> #include <infiniband/manadv.h>
Signature · 1 line
2.53.0
RFC 10/21 gro: include headers directly
In reply to Stephen HemmingerThe gro library was getting header such as vxlan implicitly via rte_ethdev.h. That will change so get the headers where used instead.
--- lib/gro/gro_tcp4.c | 1 + lib/gro/gro_vxlan_tcp4.c | 4 +++- lib/gro/gro_vxlan_udp4.c | 1 + lib/gro/rte_gro.c | 1 + 4 files changed, 6 insertions(+), 1 deletion(-)
lib/gro/gro_tcp4.c +1 -0
@@ -5,6 +5,7 @@#include <rte_malloc.h> #include <rte_mbuf.h> #include <rte_ethdev.h> +#include <rte_ip.h> #include "gro_tcp4.h" #include "gro_tcp_internal.h"
lib/gro/gro_vxlan_tcp4.c +3 -1
@@ -5,7 +5,9 @@#include <rte_malloc.h> #include <rte_mbuf.h> #include <rte_ethdev.h> -#include <rte_udp.h> +#include <rte_vxlan.h> +#include <rte_ip.h> +#include <rte_tcp.h> #include "gro_vxlan_tcp4.h"
lib/gro/gro_vxlan_udp4.c +1 -0
@@ -5,6 +5,7 @@#include <rte_malloc.h> #include <rte_mbuf.h> #include <rte_ethdev.h> +#include <rte_vxlan.h> #include <rte_udp.h> #include "gro_vxlan_udp4.h"
lib/gro/rte_gro.c +1 -0
@@ -6,6 +6,7 @@#include <rte_malloc.h> #include <rte_cycles.h> #include <rte_ethdev.h> +#include <rte_vxlan.h> #include "rte_gro.h" #include "gro_tcp4.h"
Signature · 1 line
2.53.0
RFC 11/21 test: include headers directly
In reply to Stephen HemmingerThe test code was getting network headers indirectly via inclusion of rte_ethdev.h. This will change in future, instead get the headers directly.
--- app/test-eventdev/test_pipeline_common.h | 1 + app/test/test_bpf.c | 3 +++ app/test/test_security_inline_macsec.c | 2 ++ app/test/test_security_inline_proto.c | 1 + 4 files changed, 7 insertions(+)
app/test-eventdev/test_pipeline_common.h +1 -0
@@ -12,6 +12,7 @@#include <rte_cycles.h> #include <rte_ethdev.h> #include <rte_ether.h> +#include <rte_ip.h> #include <rte_event_eth_rx_adapter.h> #include <rte_event_eth_tx_adapter.h> #include <rte_eventdev.h>
app/test/test_bpf.c +3 -0
@@ -15,6 +15,9 @@#include <rte_random.h> #include <rte_byteorder.h> #include <rte_errno.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> #include "test.h"
app/test/test_security_inline_macsec.c +2 -0
@@ -8,6 +8,8 @@#include <rte_ethdev.h> #include <rte_malloc.h> #include <rte_security.h> +#include <rte_flow.h> +#include <rte_macsec.h> #include "test.h" #include "test_security_inline_macsec_vectors.h"
app/test/test_security_inline_proto.c +1 -0
@@ -7,6 +7,7 @@#include <inttypes.h> #include <rte_ethdev.h> +#include <rte_flow.h> #include <rte_malloc.h> #include <rte_security.h>
Signature · 1 line
2.53.0
RFC 12/21 node: get UDP header
In reply to Stephen HemmingerThis library was getting udp header indirectly via rte_ethdev.h
--- lib/node/udp4_input.c | 1 + 1 file changed, 1 insertion(+)
lib/node/udp4_input.c +1 -0
@@ -11,6 +11,7 @@#include <rte_graph.h> #include <rte_graph_worker.h> #include <rte_ip.h> +#include <rte_udp.h> #include <rte_lpm.h> #include <rte_hash.h> #include <rte_fbk_hash.h>
Signature · 1 line
2.53.0
RFC 13/21 net/rnp: include network headers
In reply to Stephen HemmingerThe driver was getting definition of standard network protocol headers indirectly from rte_ethdev.h
--- drivers/net/rnp/rnp_rxtx.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/net/rnp/rnp_rxtx.c +6 -0
@@ -8,6 +8,12 @@#include <rte_memzone.h> #include <rte_mbuf.h> #include <rte_malloc.h> +#include <rte_vxlan.h> +#include <rte_ip.h> +#include <rte_gre.h> +#include <rte_udp.h> +#include <rte_tcp.h> +#include <rte_sctp.h> #include "base/rnp_bdq_if.h" #include "base/rnp_dma_regs.h"
Signature · 1 line
2.53.0
RFC 14/21 net/r8169: get network headers
In reply to Stephen HemmingerThis driver was getting network protocol headers indirectly via rte_ethdev.h
--- drivers/net/r8169/r8169_rxtx.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/r8169/r8169_rxtx.c +3 -0
@@ -20,6 +20,9 @@#include <rte_memory.h> #include <rte_malloc.h> #include <dev_driver.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> #include "r8169_ethdev.h" #include "r8169_hw.h"
Signature · 1 line
2.53.0
RFC 15/21 net/ngbe: include network protocol headers
In reply to Stephen HemmingerDo not depend on network protocol headers getting included via rte_ethdev.h
--- drivers/net/ngbe/ngbe_rxtx.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/net/ngbe/ngbe_rxtx.c +4 -0
@@ -11,6 +11,10 @@#include <rte_malloc.h> #include <rte_net.h> #include <rte_vect.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> +#include <rte_sctp.h> #include "ngbe_logs.h" #include "base/ngbe.h"
Signature · 1 line
2.53.0
RFC 16/21 examples: include network headers
In reply to Stephen HemmingerDon't depend on network protocol headers getting indirectly included via rte_ethdev.h
--- examples/l2fwd-macsec/main.c | 2 ++ examples/l3fwd-graph/main.c | 1 + examples/l3fwd/l3fwd.h | 2 ++ 3 files changed, 5 insertions(+)
examples/l2fwd-macsec/main.c +2 -0
@@ -33,9 +33,11 @@#include <rte_debug.h> #include <rte_ether.h> #include <rte_ethdev.h> +#include <rte_flow.h> #include <rte_mempool.h> #include <rte_mbuf.h> #include <rte_security.h> +#include <rte_macsec.h> #include <rte_string_fns.h> static volatile bool force_quit;
examples/l3fwd-graph/main.c +1 -0
@@ -36,6 +36,7 @@#include <rte_per_lcore.h> #include <rte_string_fns.h> #include <rte_vect.h> +#include <rte_ip.h> #include <cmdline_parse.h> #include <cmdline_parse_etheraddr.h>
examples/l3fwd/l3fwd.h +2 -0
@@ -8,6 +8,8 @@#include <rte_ethdev.h> #include <rte_vect.h> #include <rte_acl.h> +#include <rte_ip.h> +#define DO_RFC_1812_CHECKS
Signature · 1 line
2.53.0
RFC 17/21 net/mlx5: include rte_flow as needed
In reply to Stephen HemmingerThe driver was getting rte_flow.h included indirectly via rte_ethdev.h. This will change in future and driver should include it where needed.
--- drivers/net/mlx5/mlx5_ethdev.c | 1 + drivers/net/mlx5/mlx5_flow.h | 1 + drivers/net/mlx5/mlx5_txq.c | 1 + drivers/net/mlx5/mlx5_utils.c | 1 + drivers/net/mlx5/mlx5_utils.h | 1 + 5 files changed, 5 insertions(+)
drivers/net/mlx5/mlx5_ethdev.c +1 -0
@@ -19,6 +19,7 @@#include <rte_string_fns.h> #include <rte_rwlock.h> #include <rte_cycles.h> +#include <rte_flow.h> #include <mlx5_malloc.h>
drivers/net/mlx5/mlx5_flow.h +1 -0
@@ -12,6 +12,7 @@#include <rte_alarm.h> #include <rte_mtr.h> +#include <rte_flow.h> #include <mlx5_glue.h> #include <mlx5_prm.h>
drivers/net/mlx5/mlx5_txq.c +1 -0
@@ -18,6 +18,7 @@#include <rte_common.h> #include <rte_eal_paging.h> #include <rte_bitops.h> +#include <rte_flow.h> #include <mlx5_common.h> #include <mlx5_common_mr.h>
drivers/net/mlx5/mlx5_utils.c +1 -0
@@ -3,6 +3,7 @@*/ #include <rte_malloc.h> +#include <rte_flow.h> #include <mlx5_malloc.h>
drivers/net/mlx5/mlx5_utils.h +1 -0
@@ -16,6 +16,7 @@#include <rte_rwlock.h> #include <rte_memory.h> #include <rte_bitmap.h> +#include <rte_flow.h> #include <mlx5_common.h> #include <mlx5_common_utils.h>
Signature · 1 line
2.53.0
RFC 18/21 net/sfc: include rte_flow
In reply to Stephen HemmingerThis driver was depending on rte_ethdev.h doing inclusion of rte_flow.h
--- drivers/net/sfc/sfc_dp.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/sfc/sfc_dp.c +1 -0
@@ -15,6 +15,7 @@#include <rte_ethdev.h> #include <rte_log.h> #include <rte_mbuf_dyn.h> +#include <rte_flow.h> #include "efx.h"
Signature · 1 line
2.53.0
RFC 19/21 net/intel: include network headers
In reply to Stephen HemmingerThis file was depending on network protocol headers getting included via rte_ethdev.h -> rte_flow.h
--- drivers/net/intel/common/tx_scalar.h | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/intel/common/tx_scalar.h +3 -0
@@ -8,6 +8,9 @@#include <stdint.h> #include <rte_io.h> #include <rte_byteorder.h> +#include <rte_udp.h> +#include <rte_tcp.h> +#include <rte_sctp.h> /* depends on common Tx definitions. */ #include "tx.h"
Signature · 1 line
2.53.0
RFC 20/21 ethdev, drivers: isolate flow director
In reply to Stephen HemmingerThere are leftover bits of legacy flow director that are still being used by drivers. Move the definitions contained in ethdev_driver.h and rte_eth_ctrl.h into a single file ethdev_fdir.h and only include it in the drivers that require it.
---
doc/api/doxy-api-index.md | 1 -
drivers/net/hinic/hinic_pmd_ethdev.h | 2 +
drivers/net/hinic3/hinic3_ethdev.h | 1 +
drivers/net/intel/cpfl/cpfl_flow_engine_fxp.c | 2 +-
drivers/net/intel/e1000/e1000_ethdev.h | 1 +
drivers/net/intel/e1000/igc_filter.h | 2 +-
drivers/net/intel/i40e/i40e_ethdev.h | 1 +
drivers/net/intel/iavf/iavf_fsub.c | 2 +-
drivers/net/intel/iavf/iavf_hash.c | 2 +-
drivers/net/intel/ice/ice_acl_filter.c | 2 +-
drivers/net/intel/ice/ice_ethdev.h | 2 +
drivers/net/intel/ice/ice_generic_flow.c | 1 +
drivers/net/intel/ice/ice_hash.c | 2 +-
drivers/net/intel/ice/ice_switch_filter.c | 2 +-
drivers/net/intel/ipn3ke/ipn3ke_flow.c | 2 +-
drivers/net/intel/ixgbe/ixgbe_ethdev.h | 1 +
drivers/net/nbl/nbl_include/nbl_include.h | 1 +
drivers/net/txgbe/txgbe_ethdev.h | 1 +
lib/ethdev/ethdev_driver.h | 36 ------------
lib/ethdev/{rte_eth_ctrl.h => ethdev_fdir.h} | 58 ++++++++++++++-----
lib/ethdev/meson.build | 2 +-
lib/ethdev/rte_ethdev.h | 13 +----
22 files changed, 67 insertions(+), 70 deletions(-)
rename lib/ethdev/{rte_eth_ctrl.h => ethdev_fdir.h} (91%)doc/api/doxy-api-index.md +0 -1
@@ -11,7 +11,6 @@ The public API headers are grouped by topics: - **device**: [dev](@ref rte_dev.h), [ethdev](@ref rte_ethdev.h), - [ethctrl](@ref rte_eth_ctrl.h), [rte_flow](@ref rte_flow.h), [rte_tm](@ref rte_tm.h), [rte_mtr](@ref rte_mtr.h),
drivers/net/hinic/hinic_pmd_ethdev.h +2 -0
@@ -7,7 +7,9 @@#include <rte_ethdev.h> #include <rte_ethdev_core.h> +#include <rte_flow.h> #include <ethdev_driver.h> +#include <ethdev_fdir.h> #include "base/hinic_compat.h" #include "base/hinic_pmd_cfg.h"
drivers/net/hinic3/hinic3_ethdev.h +1 -0
@@ -7,6 +7,7 @@#include <rte_ethdev.h> #include <rte_ethdev_core.h> +#include <ethdev_fdir.h> #include "hinic3_fdir.h"
drivers/net/intel/cpfl/cpfl_flow_engine_fxp.c +1 -1
@@ -16,7 +16,7 @@#include <rte_ether.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_flow_driver.h> #include <rte_flow.h>
drivers/net/intel/e1000/e1000_ethdev.h +1 -0
@@ -9,6 +9,7 @@#include <sys/queue.h> #include <rte_flow.h> +#include <ethdev_fdir.h> #include <rte_time.h> #include <rte_pci.h>
drivers/net/intel/e1000/igc_filter.h +1 -1
@@ -8,7 +8,7 @@#include <rte_ethdev.h> #include <rte_ethdev_core.h> #include <ethdev_driver.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include "igc_ethdev.h"
drivers/net/intel/i40e/i40e_ethdev.h +1 -0
@@ -13,6 +13,7 @@#include <rte_hash.h> #include <rte_flow.h> #include <rte_flow_driver.h> +#include <ethdev_fdir.h> #include <rte_tm_driver.h> #include "rte_pmd_i40e.h" #include <rte_vect.h>
drivers/net/intel/iavf/iavf_fsub.c +1 -1
@@ -14,7 +14,7 @@#include <rte_ethdev.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_flow_driver.h> #include <rte_flow.h>
drivers/net/intel/iavf/iavf_hash.c +1 -1
@@ -15,7 +15,7 @@#include <ethdev_driver.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_flow_driver.h>
drivers/net/intel/ice/ice_acl_filter.c +1 -1
@@ -13,9 +13,9 @@#include <rte_debug.h> #include <rte_ether.h> #include <ethdev_driver.h> +#include <ethdev_fdir.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> #include <rte_tailq.h> #include <rte_flow_driver.h> #include <rte_flow.h>
drivers/net/intel/ice/ice_ethdev.h +2 -0
@@ -8,8 +8,10 @@#include <rte_compat.h> #include <rte_kvargs.h> #include <rte_time.h> +#include <rte_flow.h> #include <ethdev_driver.h> +#include <ethdev_fdir.h> #include <rte_tm_driver.h> #include <rte_vect.h>
drivers/net/intel/ice/ice_generic_flow.c +1 -0
@@ -13,6 +13,7 @@#include <rte_ether.h> #include <ethdev_driver.h> +#include <ethdev_fdir.h> #include <rte_hexdump.h> #include <rte_malloc.h> #include <rte_tailq.h>
drivers/net/intel/ice/ice_hash.c +1 -1
@@ -16,7 +16,7 @@#include <ethdev_driver.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_flow_driver.h>
drivers/net/intel/ice/ice_switch_filter.c +1 -1
@@ -15,7 +15,7 @@#include <ethdev_driver.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_flow_driver.h> #include <rte_flow.h>
drivers/net/intel/ipn3ke/ipn3ke_flow.c +1 -1
@@ -16,7 +16,7 @@#include <ethdev_driver.h> #include <rte_log.h> #include <rte_malloc.h> -#include <rte_eth_ctrl.h> +#include <ethdev_fdir.h> #include <rte_tailq.h> #include <rte_rawdev.h> #include <rte_rawdev_pmd.h>
drivers/net/intel/ixgbe/ixgbe_ethdev.h +1 -0
@@ -16,6 +16,7 @@#include "ixgbe_bypass.h" #include "ixgbe_ipsec.h" #include <rte_flow.h> +#include <ethdev_fdir.h> #include <rte_time.h> #include <rte_hash.h> #include <rte_pci.h>
drivers/net/nbl/nbl_include/nbl_include.h +1 -0
@@ -27,6 +27,7 @@#include <rte_alarm.h> #include <rte_ethdev.h> +#include <rte_flow.h> #include <ethdev_driver.h> #include <ethdev_pci.h> #include <bus_pci_driver.h>
drivers/net/txgbe/txgbe_ethdev.h +1 -0
@@ -18,6 +18,7 @@#include <rte_time.h> #include <rte_ethdev.h> #include <rte_ethdev_core.h> +#include <ethdev_fdir.h> #include <rte_hash.h> #include <rte_hash_crc.h> #include <bus_pci_driver.h>
lib/ethdev/ethdev_driver.h +0 -36
@@ -2365,42 +2365,6 @@ struct rte_eth_tunnel_filter_conf {uint16_t queue_id;/**< Queue assigned to if match */ }; -/** -* Memory space that can be configured to store Flow Director filters -* in the board memory. -*/ -enum rte_eth_fdir_pballoc_type { -RTE_ETH_FDIR_PBALLOC_64K =0 ,/**< 64k. */ -RTE_ETH_FDIR_PBALLOC_128K ,/**< 128k. */ -RTE_ETH_FDIR_PBALLOC_256K ,/**< 256k. */ -}; - -/** -* Select report mode of FDIR hash information in Rx descriptors. -*/ -enum rte_fdir_status_mode { -RTE_FDIR_NO_REPORT_STATUS =0 ,/**< Never report FDIR hash. */ -RTE_FDIR_REPORT_STATUS ,/**< Only report FDIR hash for matching pkts. */ -RTE_FDIR_REPORT_STATUS_ALWAYS ,/**< Always report FDIR hash. */ -}; - -/** -* A structure used to configure the Flow Director (FDIR) feature -* of an Ethernet port. -* -* If mode is RTE_FDIR_MODE_NONE, the pballoc value is ignored. -*/ -struct rte_eth_fdir_conf { -enum rte_fdir_mode mode;/**< Flow Director mode. */ -enum rte_eth_fdir_pballoc_type pballoc;/**< Space for FDIR filters. */ -enum rte_fdir_status_mode status;/**< How to report FDIR hash. */ -/** Rx queue of packets matching a "drop" filter in perfect mode. */ -uint8_t drop_queue; -struct rte_eth_fdir_masks mask; -/** Flex payload configuration. */ -struct rte_eth_fdir_flex_conf flex_conf; -}; -/** * @internal * Fetch from the driver what kind of configuration must be restored by ethdev layer,
lib/ethdev/ethdev_fdir.h renamed from lib/ethdev/rte_eth_ctrl.h +45 -13
73 lines not on this page · raw message
lib/ethdev/meson.build +1 -1
@@ -32,11 +32,11 @@ headers = files( indirect_headers += files( 'rte_ethdev_core.h', - 'rte_eth_ctrl.h', ) driver_sdk_headers += files( 'ethdev_driver.h', + 'ethdev_fdir.h', 'ethdev_pci.h', 'ethdev_vdev.h', 'rte_flow_driver.h',
lib/ethdev/rte_ethdev.h +2 -11
@@ -164,8 +164,10 @@#include <rte_devargs.h> #include <rte_bitops.h> #include <rte_errno.h> +#include <rte_ether.h> #include <rte_common.h> #include <rte_config.h> +#include <rte_mbuf_history.h> #include <rte_power_intrinsics.h> #include "rte_ethdev_trace_fp.h"
@@ -1505,17 +1507,6 @@ enum rte_eth_tunnel_type { RTE_ETH_TUNNEL_TYPE_MAX, }; -#ifdef __cplusplus -} -#endif - -/* Deprecated API file for rte_eth_dev_filter_* functions */ -#include "rte_eth_ctrl.h" - -#ifdef __cplusplus -extern "C" { -#endif -/** * UDP tunneling configuration. *
Signature · 1 line
2.53.0
RFC 21/21 doc: add release not about rte_ethdev changes
In reply to Stephen HemmingerThe changes to rte_ethdev are visible to applications. This may require straight forward include file changes.
--- doc/guides/rel_notes/release_26_11.rst | 13 +++++++++++++ 1 file changed, 13 insertions(+)
doc/guides/rel_notes/release_26_11.rst +13 -0
@@ -77,6 +77,12 @@ Removed Items ``rte_rib6_is_equal`` * table: ``RTE_LPM_IPV6_ADDR_SIZE`` +* Experimental flow director related API's have been removed: + + * Testpmd: ``show port fdir`` + * ixgbe: ``rte_pmd_ixgbe_get_fdir_info``, ``rte_pmd_ixgbe_get_fdir_stats`` + * i40e: ``rte_pmd_i40e_get_fdir_info``, ``rte_pmd_i40e_get_fdir_stats`` + API Changes -----------
@@ -93,6 +99,13 @@ API Changes Also, make sure to start the actual text at the margin. ======================================================= +* **Changed ethdev include files.** + + * Dropped inclusion of ``rte_flow.h`` in ``rte_ethdev.h``. + * Network headers ``rte_ip.h``, ``rte_udp.h``, ``rte_tcp.h`` and ``rte_sctp.h`` + are no longer indirectly included by ``rte_ethdev.h``. + * Legacy flow director definitions are no longer included by ``rte_ethdev.h``. + ABI Changes -----------
Signature · 1 line
2.53.0
RE: [RFC 11/21] test: include headers directly
In reply to Stephen HemmingerQuoted 5 lines
app/test/test_bpf.c +0
-0
app/test/test_bpf.c line 23
Quoted 9 lines
app/test/test_bpf.c +3
-0@@ -15,6 +15,9 @@#include <rte_random.h> #include <rte_byteorder.h> #include <rte_errno.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> #include "test.h"
This file has another group of includes guarded by RTE_LIB_BPF several lines below, with #include <rte_ip.h> already there. It also seems that the guard is redundant since meson.build already declares same dependency. We probably should avoid adding duplicates, and optionally also do a cleanup here.
With test_pipeline_common.h I could not find what uses the newly added header. Other changed files have guards against MSVC which are not redundant. If the new includes were added under this guard I could probably ack the change as harmless, but as is the opinion of other maintainers is needed. So maybe splitting the commit per-file would accelerate the process.
Obvious question is if we could have some general policy and tools. Explicit includes are good, but whack-a-mole approach can only go so far.
Re: [RFC 11/21] test: include headers directly
Quoted 20 lines · On Sun, 2 Aug 2026 19:37:04 +0000 Marat Khalili <[email protected]>…
Quoted 5 lines
app/test/test_bpf.c +0
-0app/test/test_bpf.c line 23
Quoted 9 lines
app/test/test_bpf.c +3
-0@@ -15,6 +15,9 @@#include <rte_random.h> #include <rte_byteorder.h> #include <rte_errno.h> +#include <rte_ip.h> +#include <rte_udp.h> +#include <rte_tcp.h> #include "test.h" This file has another group of includes guarded by
RTE_LIB_BPFseveral lines below, with#include <rte_ip.h>already there. It also seems that the guard is redundant sincemeson.buildalready declares same dependency. We probably should avoid adding duplicates, and optionally also do a cleanup here.
Quoted 9 lines
With
test_pipeline_common.hI could not find what uses the newly added header. Other changed files have guards against MSVC which are not redundant. If the new includes were added under this guard I could probably ack the change as harmless, but as is the opinion of other maintainers is needed. So maybe splitting the commit per-file would accelerate the process.Obvious question is if we could have some general policy and tools. Explicit includes are good, but whack-a-mole approach can only go so far.
Good point. There is a good existing tool 'iwyu' that does this. Will use that.