[PATCH 188/227] examples/ethtool: use NUMA node terminology
Chengwen Feng
chengwen.feng at linux.dev
Tue Nov 3 15:52:26 CET 2026
From: Chengwen Feng <fengchengwen at huawei.com>
Rename socket_id parameters, local variables and comments to the
NUMA node terminology, and switch calls to the NUMA-named APIs.
Signed-off-by: Chengwen Feng <fengchengwen at huawei.com>
---
examples/ethtool/ethtool-app/main.c | 6 +++---
examples/ethtool/lib/rte_ethtool.c | 4 ++--
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/examples/ethtool/ethtool-app/main.c b/examples/ethtool/ethtool-app/main.c
index ddd256cd7b..bd87e5430d 100644
--- a/examples/ethtool/ethtool-app/main.c
+++ b/examples/ethtool/ethtool-app/main.c
@@ -118,7 +118,7 @@ static void setup_ports(struct app_config *ptr_cfg, int cnt_ports)
size_pktpool, PKTPOOL_CACHE,
0,
RTE_MBUF_DEFAULT_BUF_SIZE,
- rte_socket_id()
+ rte_numa_id()
);
if (ptr_port->pkt_pool == NULL)
rte_exit(EXIT_FAILURE,
@@ -140,14 +140,14 @@ static void setup_ports(struct app_config *ptr_cfg, int cnt_ports)
if (rte_eth_rx_queue_setup(
idx_port, 0, nb_rxd,
- rte_eth_dev_socket_id(idx_port), NULL,
+ rte_eth_dev_numa_id(idx_port), NULL,
ptr_port->pkt_pool) < 0)
rte_exit(EXIT_FAILURE,
"rte_eth_rx_queue_setup failed"
);
if (rte_eth_tx_queue_setup(
idx_port, 0, nb_txd,
- rte_eth_dev_socket_id(idx_port), NULL) < 0)
+ rte_eth_dev_numa_id(idx_port), NULL) < 0)
rte_exit(EXIT_FAILURE,
"rte_eth_tx_queue_setup failed"
);
diff --git a/examples/ethtool/lib/rte_ethtool.c b/examples/ethtool/lib/rte_ethtool.c
index 0b88a27e7d..b3edbc71ad 100644
--- a/examples/ethtool/lib/rte_ethtool.c
+++ b/examples/ethtool/lib/rte_ethtool.c
@@ -444,12 +444,12 @@ rte_ethtool_set_ringparam(uint16_t port_id,
return stat;
stat = rte_eth_tx_queue_setup(port_id, 0, ring_param->tx_pending,
- rte_eth_dev_socket_id(port_id), NULL);
+ rte_eth_dev_numa_id(port_id), NULL);
if (stat != 0)
return stat;
stat = rte_eth_rx_queue_setup(port_id, 0, ring_param->rx_pending,
- rte_eth_dev_socket_id(port_id), NULL, rx_qinfo.mp);
+ rte_eth_dev_numa_id(port_id), NULL, rx_qinfo.mp);
if (stat != 0)
return stat;
--
2.55.0
More information about the dev
mailing list