[PATCH 192/227] examples/ip_fragmentation: use NUMA node terminology

Chengwen Feng chengwen.feng at linux.dev
Tue Nov 3 15:52:30 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/ip_fragmentation/main.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/examples/ip_fragmentation/main.c b/examples/ip_fragmentation/main.c
index 132550e497..d429f526e1 100644
--- a/examples/ip_fragmentation/main.c
+++ b/examples/ip_fragmentation/main.c
@@ -788,9 +788,9 @@ init_mem(void)
 		if (rte_lcore_is_enabled(lcore_id) == 0)
 			continue;
 
-		socket = rte_lcore_to_socket_id(lcore_id);
+		socket = rte_lcore_to_numa_id(lcore_id);
 
-		if (socket == SOCKET_ID_ANY)
+		if (socket == RTE_NUMA_ID_ANY)
 			socket = 0;
 
 		if (socket_direct_pool[socket] == NULL) {
@@ -928,8 +928,8 @@ main(int argc, char **argv)
 			qconf = &lcore_queue_conf[rx_lcore_id];
 		}
 
-		socket = (int) rte_lcore_to_socket_id(rx_lcore_id);
-		if (socket == SOCKET_ID_ANY)
+		socket = (int) rte_lcore_to_numa_id(rx_lcore_id);
+		if (socket == RTE_NUMA_ID_ANY)
 			socket = 0;
 
 		rxq = &qconf->rx_queue_list[qconf->n_rx_queue];
@@ -1011,7 +1011,7 @@ main(int argc, char **argv)
 			if (queueid >= dev_info.nb_tx_queues)
 				break;
 
-			socket = (int) rte_lcore_to_socket_id(lcore_id);
+			socket = (int) rte_lcore_to_numa_id(lcore_id);
 			printf("txq=%u,%d ", lcore_id, queueid);
 			fflush(stdout);
 
-- 
2.55.0



More information about the dev mailing list