[dpdk-stable] patch 'app/testpmd: reserve NUMA node per port and per ring' has been queued to LTS release 17.11.5
Yongseok Koh
yskoh at mellanox.com
Fri Nov 30 00:11:09 CET 2018
Hi,
FYI, your patch has been queued to LTS release 17.11.5
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/01/18. So please
shout if anyone has objections.
Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.
Thanks.
Yongseok
---
>From c58c45cbdeb845d4b308d9a489e8454fc08744c2 Mon Sep 17 00:00:00 2001
From: Phil Yang <phil.yang at arm.com>
Date: Thu, 18 Oct 2018 18:39:25 +0800
Subject: [PATCH] app/testpmd: reserve NUMA node per port and per ring
[ upstream commit a569af2481cd3bd29e5c6d49f2d2f95586d750a8 ]
If user explicitly requested memory to be allocated from a socket via
`port-numa-config` and `ring-numa-config`, and if that socket is
valid, add that socket into socket_ids[] so that mempool allocated for
that socket.
Fixes: dbfb8ec7094c ("app/testpmd: optimize mbuf pool allocation")
Suggested-by: Ferruh Yigit <ferruh.yigit at intel.com>
Signed-off-by: Phil Yang <phil.yang at arm.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit at intel.com>
---
app/test-pmd/parameters.c | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
index 5d51808f5..1dfbcc4f9 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
@@ -431,8 +431,11 @@ parse_portnuma_config(const char *q_arg)
}
socket_id = (uint8_t)int_fld[FLD_SOCKET];
if (new_socket_id(socket_id)) {
- print_invalid_socket_id_error();
- return -1;
+ if (num_sockets >= RTE_MAX_NUMA_NODES) {
+ print_invalid_socket_id_error();
+ return -1;
+ }
+ socket_ids[num_sockets++] = socket_id;
}
port_numa[port_id] = socket_id;
}
@@ -488,8 +491,11 @@ parse_ringnuma_config(const char *q_arg)
}
socket_id = (uint8_t)int_fld[FLD_SOCKET];
if (new_socket_id(socket_id)) {
- print_invalid_socket_id_error();
- return -1;
+ if (num_sockets >= RTE_MAX_NUMA_NODES) {
+ print_invalid_socket_id_error();
+ return -1;
+ }
+ socket_ids[num_sockets++] = socket_id;
}
ring_flag = (uint8_t)int_fld[FLD_FLAG];
if ((ring_flag < RX_RING_ONLY) || (ring_flag > RXTX_RING)) {
--
2.11.0
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2018-11-29 15:01:48.525663110 -0800
+++ 0075-app-testpmd-reserve-NUMA-node-per-port-and-per-ring.patch 2018-11-29 15:01:45.191963000 -0800
@@ -1,15 +1,16 @@
-From a569af2481cd3bd29e5c6d49f2d2f95586d750a8 Mon Sep 17 00:00:00 2001
+From c58c45cbdeb845d4b308d9a489e8454fc08744c2 Mon Sep 17 00:00:00 2001
From: Phil Yang <phil.yang at arm.com>
Date: Thu, 18 Oct 2018 18:39:25 +0800
Subject: [PATCH] app/testpmd: reserve NUMA node per port and per ring
+[ upstream commit a569af2481cd3bd29e5c6d49f2d2f95586d750a8 ]
+
If user explicitly requested memory to be allocated from a socket via
`port-numa-config` and `ring-numa-config`, and if that socket is
valid, add that socket into socket_ids[] so that mempool allocated for
that socket.
Fixes: dbfb8ec7094c ("app/testpmd: optimize mbuf pool allocation")
-Cc: stable at dpdk.org
Suggested-by: Ferruh Yigit <ferruh.yigit at intel.com>
Signed-off-by: Phil Yang <phil.yang at arm.com>
@@ -19,10 +20,10 @@
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
-index 4a4debb8d..38b419767 100644
+index 5d51808f5..1dfbcc4f9 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
-@@ -416,8 +416,11 @@ parse_portnuma_config(const char *q_arg)
+@@ -431,8 +431,11 @@ parse_portnuma_config(const char *q_arg)
}
socket_id = (uint8_t)int_fld[FLD_SOCKET];
if (new_socket_id(socket_id)) {
@@ -36,7 +37,7 @@
}
port_numa[port_id] = socket_id;
}
-@@ -473,8 +476,11 @@ parse_ringnuma_config(const char *q_arg)
+@@ -488,8 +491,11 @@ parse_ringnuma_config(const char *q_arg)
}
socket_id = (uint8_t)int_fld[FLD_SOCKET];
if (new_socket_id(socket_id)) {
More information about the stable
mailing list