summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorDavid Marchand <david.marchand@redhat.com>2022-10-04 10:01:16 +0200
committerDavid Marchand <david.marchand@redhat.com>2022-10-05 21:34:40 +0200
commit4ed890495594a71e618d62fd975c5868915eb4a1 (patch)
tree9934f16daaf3e0757218d343d1c8cf75a9bf1939 /app
parent1a852c1e879601222ec217d315bc911194ad6879 (diff)
remove prefix to some local macros in apps and examples
RTE_TEST_[RT]X_DESC_DEFAULT and RTE_TEST_[RT]X_DESC_MAX macros have been copied in a lot of app/ and examples/ code. Those macros are local to each program. They are not related to a DPDK public header/API, drop the RTE_TEST_ prefix. Signed-off-by: David Marchand <david.marchand@redhat.com> Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
Diffstat (limited to 'app')
-rw-r--r--app/test-pmd/testpmd.c12
-rw-r--r--app/test-pmd/testpmd.h6
-rw-r--r--app/test/test_link_bonding.c8
-rw-r--r--app/test/test_pmd_perf.c8
-rw-r--r--app/test/test_security_inline_proto.c8
5 files changed, 21 insertions, 21 deletions
diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index de6ad00138..39ee3d331d 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -288,10 +288,10 @@ queueid_t nb_txq = 1; /**< Number of TX queues per port. */
* Configurable number of RX/TX ring descriptors.
* Defaults are supplied by drivers via ethdev.
*/
-#define RTE_TEST_RX_DESC_DEFAULT 0
-#define RTE_TEST_TX_DESC_DEFAULT 0
-uint16_t nb_rxd = RTE_TEST_RX_DESC_DEFAULT; /**< Number of RX descriptors. */
-uint16_t nb_txd = RTE_TEST_TX_DESC_DEFAULT; /**< Number of TX descriptors. */
+#define RX_DESC_DEFAULT 0
+#define TX_DESC_DEFAULT 0
+uint16_t nb_rxd = RX_DESC_DEFAULT; /**< Number of RX descriptors. */
+uint16_t nb_txd = TX_DESC_DEFAULT; /**< Number of TX descriptors. */
#define RTE_PMD_PARAM_UNSET -1
/*
@@ -1719,9 +1719,9 @@ init_config(void)
if (param_total_num_mbufs)
nb_mbuf_per_pool = param_total_num_mbufs;
else {
- nb_mbuf_per_pool = RTE_TEST_RX_DESC_MAX +
+ nb_mbuf_per_pool = RX_DESC_MAX +
(nb_lcores * mb_mempool_cache) +
- RTE_TEST_TX_DESC_MAX + MAX_PKT_BURST;
+ TX_DESC_MAX + MAX_PKT_BURST;
nb_mbuf_per_pool *= RTE_MAX_ETHPORTS;
}
diff --git a/app/test-pmd/testpmd.h b/app/test-pmd/testpmd.h
index a7b8565a6d..627a42ce3b 100644
--- a/app/test-pmd/testpmd.h
+++ b/app/test-pmd/testpmd.h
@@ -28,9 +28,6 @@
#define RTE_PORT_ALL (~(portid_t)0x0)
-#define RTE_TEST_RX_DESC_MAX 2048
-#define RTE_TEST_TX_DESC_MAX 2048
-
#define RTE_PORT_STOPPED (uint16_t)0
#define RTE_PORT_STARTED (uint16_t)1
#define RTE_PORT_CLOSED (uint16_t)2
@@ -67,6 +64,9 @@ extern uint8_t cl_quit;
/* The prefix of the mbuf pool names created by the application. */
#define MBUF_POOL_NAME_PFX "mb_pool"
+#define RX_DESC_MAX 2048
+#define TX_DESC_MAX 2048
+
#define MAX_PKT_BURST 512
#define DEF_PKT_BURST 32
diff --git a/app/test/test_link_bonding.c b/app/test/test_link_bonding.c
index 194ed5a7ec..c28c1ada46 100644
--- a/app/test/test_link_bonding.c
+++ b/app/test/test_link_bonding.c
@@ -47,8 +47,8 @@
#define MBUF_CACHE_SIZE (250)
#define BURST_SIZE (32)
-#define RTE_TEST_RX_DESC_MAX (2048)
-#define RTE_TEST_TX_DESC_MAX (2048)
+#define RX_DESC_MAX (2048)
+#define TX_DESC_MAX (2048)
#define MAX_PKT_BURST (512)
#define DEF_PKT_BURST (16)
@@ -225,8 +225,8 @@ test_setup(void)
"Ethernet header struct allocation failed!");
}
- nb_mbuf_per_pool = RTE_TEST_RX_DESC_MAX + DEF_PKT_BURST +
- RTE_TEST_TX_DESC_MAX + MAX_PKT_BURST;
+ nb_mbuf_per_pool = RX_DESC_MAX + DEF_PKT_BURST +
+ TX_DESC_MAX + MAX_PKT_BURST;
if (test_params->mbuf_pool == NULL) {
test_params->mbuf_pool = rte_pktmbuf_pool_create("MBUF_POOL",
nb_mbuf_per_pool, MBUF_CACHE_SIZE, 0,
diff --git a/app/test/test_pmd_perf.c b/app/test/test_pmd_perf.c
index ec3dc251d1..10dba0da88 100644
--- a/app/test/test_pmd_perf.c
+++ b/app/test/test_pmd_perf.c
@@ -18,8 +18,8 @@
#define NB_SOCKETS (2)
#define MEMPOOL_CACHE_SIZE 250
#define MAX_PKT_BURST (32)
-#define RTE_TEST_RX_DESC_DEFAULT (1024)
-#define RTE_TEST_TX_DESC_DEFAULT (1024)
+#define RX_DESC_DEFAULT (1024)
+#define TX_DESC_DEFAULT (1024)
#define RTE_PORT_ALL (~(uint16_t)0x0)
/* how long test would take at full line rate */
@@ -703,8 +703,8 @@ test_pmd_perf(void)
init_mbufpool(NB_MBUF);
if (sc_flag == SC_CONTINUOUS) {
- nb_rxd = RTE_TEST_RX_DESC_DEFAULT;
- nb_txd = RTE_TEST_TX_DESC_DEFAULT;
+ nb_rxd = RX_DESC_DEFAULT;
+ nb_txd = TX_DESC_DEFAULT;
}
printf("CONFIG RXD=%d TXD=%d\n", nb_rxd, nb_txd);
diff --git a/app/test/test_security_inline_proto.c b/app/test/test_security_inline_proto.c
index f54cc90322..07819626bc 100644
--- a/app/test/test_security_inline_proto.c
+++ b/app/test/test_security_inline_proto.c
@@ -37,8 +37,8 @@ test_event_inline_ipsec(void)
#define NB_ETHPORTS_USED 1
#define MEMPOOL_CACHE_SIZE 32
#define MAX_PKT_BURST 32
-#define RTE_TEST_RX_DESC_DEFAULT 1024
-#define RTE_TEST_TX_DESC_DEFAULT 1024
+#define RX_DESC_DEFAULT 1024
+#define TX_DESC_DEFAULT 1024
#define RTE_PORT_ALL (~(uint16_t)0x0)
#define RX_PTHRESH 8 /**< Default values of RX prefetch threshold reg. */
@@ -1506,8 +1506,8 @@ inline_ipsec_testsuite_setup(void)
printf("Generate %d packets\n", MAX_TRAFFIC_BURST);
- nb_rxd = RTE_TEST_RX_DESC_DEFAULT;
- nb_txd = RTE_TEST_TX_DESC_DEFAULT;
+ nb_rxd = RX_DESC_DEFAULT;
+ nb_txd = TX_DESC_DEFAULT;
/* configuring port 0 for the test is enough */
port_id = 0;