Skip to contentSkip to conversation

test/flow-classify: fix failure on dual socket systems

PATCH Applied Harry van Haaren 4 participants 4 messages May 1, 2020 – May 11, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 test/flow-classify: fix failure on dual socket systems

This commit fixes failures of the flow_classify_autotest when ran on dual-socket servers, as the sample application does not support more than a single socket. Increasing the NB_SOCKETS value allows the test to run successfully.

Fixes 9c9befea4f57 ("test: add flow classify unit tests")

---

DPDK does not provide a RTE_SOCKETS_MAX #define, so we cannot easily statically allocate the array. As a bugfix patch, I'd prefer not add complexity of dynamically allocating based on rte_socket_count(), hence just increasing the value seems the most pragmatic fix.

Fixes: tag is a bit complex, code was moved in previous commit. This fixes tag is against when the NB_SOCKET = 1 was introduced.

---
 app/test/test_flow_classify.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
app/test/test_flow_classify.c +1 -1
index ff5265c6a..ef0b6fdd5 100644
@@ -23,7 +23,7 @@
 
 #define FLOW_CLASSIFY_MAX_RULE_NUM 100
 #define MAX_PKT_BURST              32
-#define NB_SOCKETS                 1
+#define NB_SOCKETS                 4
 #define MEMPOOL_CACHE_SIZE         256
 #define MBUF_SIZE                  512
 #define NB_MBUF                    512
Signature · 1 line
2.17.1
Tested-by on v1 1/1
#1 lore raw
Quoted 17 lines · Harry van Haaren

This commit fixes failures of the flow_classify_autotest when ran on dual-socket servers, as the sample application does not support more than a single socket. Increasing the NB_SOCKETS value allows the test to run successfully.

Fixes 9c9befea4f57 ("test: add flow classify unit tests")

---

DPDK does not provide a RTE_SOCKETS_MAX #define, so we cannot easily statically allocate the array. As a bugfix patch, I'd prefer not add complexity of dynamically allocating based on rte_socket_count(), hence just increasing the value seems the most pragmatic fix.

Quoted 5 lines

Fixes: tag is a bit complex, code was moved in previous commit. This fixes tag is against when the NB_SOCKET = 1 was introduced.

Thanks for the fix.

Tested-by Acked-by
#2 lore raw

Hi Harry,

Quoted 27 lines

-----Original Message-----
From: Yigit, Ferruh <[email protected]>
Sent: Friday, May 1, 2020 12:51 PM
To: Van Haaren, Harry <[email protected]>; [email protected]
Cc: Iremonger, Bernard <[email protected]>; [email protected]
Subject: Re: [PATCH] test/flow-classify: fix failure on dual socket systems

Quoted 19 lines · Harry van Haaren

This commit fixes failures of the flow_classify_autotest when ran on dual-socket servers, as the sample application does not support more than a single socket. Increasing the NB_SOCKETS value allows the test to run successfully.

Fixes 9c9befea4f57 ("test: add flow classify unit tests")

---

DPDK does not provide a RTE_SOCKETS_MAX #define, so we cannot easily statically allocate the array. As a bugfix patch, I'd prefer not add complexity of dynamically allocating based on rte_socket_count(), hence just increasing the value seems the most pragmatic fix.

Fixes: tag is a bit complex, code was moved in previous commit. This fixes tag is against when the NB_SOCKET = 1 was introduced.

Quoted 7 lines
Quoted 2 lines

Thanks for the fix.

The Cc: [email protected] line should be after the fixes line in the commit message.

Otherwise

Tested-by Ferruh Yigit Tested-by Bernard Iremonger Acked-by Bernard Iremonger on v1 1/1 Applied
#3 lore raw
In reply to Harry van Haaren
Quoted 7 lines · Harry van Haaren

This commit fixes failures of the flow_classify_autotest when ran on dual-socket servers, as the sample application does not support more than a single socket. Increasing the NB_SOCKETS value allows the test to run successfully.

Fixes 9c9befea4f57 ("test: add flow classify unit tests")
Quoted 1 line

Applied.

Signature · 1 line
David Marchand