[PATCH v2 08/22] net/nfp: break implicit dependency on rte_eth_ctrl.h
Stephen Hemminger <[email protected]> Mon, 3 Aug 2026 09:51:54 -0700
| Newsgroups | org.dpdk.dev |
|---|---|
| Message-ID | <[email protected]> |
This 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. Signed-off-by: Stephen Hemminger <[email protected]> --- drivers/net/nfp/nfp_ethdev.c | 6 ++++-- drivers/net/nfp/nfp_net_common.h | 1 + 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c index d2da18013c..25be1de080 100644 --- a/drivers/net/nfp/nfp_ethdev.c +++ b/drivers/net/nfp/nfp_ethdev.c @@ -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; diff --git a/drivers/net/nfp/nfp_net_common.h b/drivers/net/nfp/nfp_net_common.h index 2bd2d54028..a479a7fbd4 100644 --- a/drivers/net/nfp/nfp_net_common.h +++ b/drivers/net/nfp/nfp_net_common.h @@ -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> -- 2.53.0