[PATCH 222/227] examples/vmdq_dcb: use NUMA node terminology

Chengwen Feng chengwen.feng at linux.dev
Tue Nov 3 15:53:00 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/vmdq_dcb/main.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/examples/vmdq_dcb/main.c b/examples/vmdq_dcb/main.c
index 563b4f9ce1..a41362984e 100644
--- a/examples/vmdq_dcb/main.c
+++ b/examples/vmdq_dcb/main.c
@@ -303,7 +303,7 @@ port_init(uint16_t port, struct rte_mempool *mbuf_pool)
 
 	for (q = 0; q < num_queues; q++) {
 		retval = rte_eth_rx_queue_setup(port, q, rxRingSize,
-					rte_eth_dev_socket_id(port),
+					rte_eth_dev_numa_id(port),
 					NULL,
 					mbuf_pool);
 		if (retval < 0) {
@@ -316,7 +316,7 @@ port_init(uint16_t port, struct rte_mempool *mbuf_pool)
 	txq_conf.offloads = port_conf.txmode.offloads;
 	for (q = 0; q < num_queues; q++) {
 		retval = rte_eth_tx_queue_setup(port, q, txRingSize,
-					rte_eth_dev_socket_id(port),
+					rte_eth_dev_numa_id(port),
 					&txq_conf);
 		if (retval < 0) {
 			printf("initialize tx queue %d failed\n", q);
@@ -687,7 +687,7 @@ main(int argc, char *argv[])
 
 	mbuf_pool = rte_pktmbuf_pool_create("MBUF_POOL",
 		NUM_MBUFS_PER_PORT * nb_ports, MBUF_CACHE_SIZE,
-		0, RTE_MBUF_DEFAULT_BUF_SIZE, rte_socket_id());
+		0, RTE_MBUF_DEFAULT_BUF_SIZE, rte_numa_id());
 	if (mbuf_pool == NULL)
 		rte_exit(EXIT_FAILURE, "Cannot create mbuf pool\n");
 
-- 
2.55.0



More information about the dev mailing list