examples/l3fwd-graph: remove redundant Tx queue limit
PATCH 1/1 examples/l3fwd-graph: remove redundant Tx queue limit
In l3fwd-graph application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/l3fwd-graph/main.c +0 -3
@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024 -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128#define MAX_RX_QUEUE_PER_LCORE 16
@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue);
Signature · 1 line
2.43.0
Quoted 45 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-4@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024 -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128#define MAX_RX_QUEUE_PER_LCORE 16@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue); --2.43.0
Quoted 33 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128
AFAIK, in the mainline we actually have:
#define MAX_TX_QUEUE_PER_PORT RTE_MAX_LCORE
since:
commit 88256ed85338c572d73006e4c4530a52d3b477ff
Author: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530
examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
Quoted 14 lines
Quoted 14 lines
examples/l3fwd-graph/main.c +0
-3#define MAX_RX_QUEUE_PER_LCORE 16@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue); --2.43.0
[AMD Official Use Only - AMD Internal Distribution Only]
Hi Konstantin,
________________________________
From: Konstantin Ananyev <[email protected]>
Sent: Monday, September 22, 2025 12:19 PM
To: Nithin Dabilpuram <[email protected]>; Tummala, Sivaprasad <[email protected]>
Cc: [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>
Subject: RE: [PATCH] examples/l3fwd-graph: remove redundant Tx queue limit
Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
Quoted 31 lines
Quoted 31 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024
Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCORE
In l3fwd-graph app, this change is not available and instead we have #define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS
Quoted 8 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Quoted 15 lines
Quoted 15 lines
Quoted 15 lines
examples/l3fwd-graph/main.c +0
-3#define MAX_RX_QUEUE_PER_LCORE 16@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue); --2.43.0
06/10/2025 10:58, Tummala, Sivaprasad:
Quoted 46 lines
From: Konstantin Ananyev <[email protected]>
Quoted 31 lines
Quoted 31 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have #define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 5 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530
Quoted 4 lines
Quoted 3 lines
examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Why not applying the same change to both examples?
[AMD Official Use Only - AMD Internal Distribution Only]
Hi Thomas,
________________________________
From: Thomas Monjalon <[email protected]>
Sent: Tuesday, November 18, 2025 10:39 PM
To: Konstantin Ananyev <[email protected]>; Tummala, Sivaprasad <[email protected]>
Cc: Nithin Dabilpuram <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>
Subject: Re: [PATCH] examples/l3fwd-graph: remove redundant Tx queue limit
Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
06/10/2025 10:58, Tummala, Sivaprasad:
Quoted 46 lines
From: Konstantin Ananyev <[email protected]>
Quoted 31 lines
Quoted 31 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have
Quoted 7 lines
#define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 5 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530
Quoted 6 lines
Quoted 4 lines
Quoted 3 lines
examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Why not applying the same change to both examples?
Yes, that's what the patch is intended for to fix l3fwd-graph and tx queues will scale with lcores and limited by RTE_MAX_LCORES.
19/11/2025 13:08, Tummala, Sivaprasad:
Quoted 48 lines
From: Thomas Monjalon <[email protected]>
06/10/2025 10:58, Tummala, Sivaprasad:Quoted 46 lines
From: Konstantin Ananyev <[email protected]>
Quoted 31 lines
Quoted 31 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have
Quoted 7 lines
#define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 5 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530
Quoted 7 lines
Quoted 6 lines
Quoted 4 lines
Quoted 3 lines
examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Why not applying the same change to both examples?
Yes, that's what the patch is intended for to fix l3fwd-graph and tx queues will scale with lcores and limited by
RTE_MAX_LCORES.
But it is not done the same way.
Here you remove MAX_TX_QUEUE_PER_PORT.
Do you want to do the same in l3fwd?
[AMD Official Use Only - AMD Internal Distribution Only]
Hi Thomas,
________________________________
From: Thomas Monjalon <[email protected]>
Sent: Wednesday, November 19, 2025 6:27 PM
To: Tummala, Sivaprasad <[email protected]>
Cc: Konstantin Ananyev <[email protected]>; Nithin Dabilpuram <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>
Subject: Re: [PATCH] examples/l3fwd-graph: remove redundant Tx queue limit
Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
19/11/2025 13:08, Tummala, Sivaprasad:
Quoted 53 lines
From: Thomas Monjalon <[email protected]>
06/10/2025 10:58, Tummala, Sivaprasad:Quoted 51 lines
From: Konstantin Ananyev <[email protected]>
Quoted 31 lines
Quoted 31 lines
Quoted 29 lines · Sivaprasad Tummala
In
l3fwd-graphapplication, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.The
MAX_TX_QUEUE_PER_PORTmacro, defined asRTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.This patch removes the unused
MAX_TX_QUEUE_PER_PORTmacro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.Fixes 08bd1a174461 ("examples/l3fwd-graph: add graph-based l3fwd skeleton")Signed-off-by Sivaprasad Tummala <[email protected]>--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have
Quoted 11 lines
#define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 9 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Quoted 6 lines
Quoted 2 lines
Quoted 1 line
Why not applying the same change to both examples?
Yes, that's what the patch is intended for to fix l3fwd-graph and tx queues will scale with lcores and limited by
RTE_MAX_LCORES.But it is not done the same way.
Here you removeMAX_TX_QUEUE_PER_PORT.
Do you want to do the same in l3fwd?
Yes, it's better to fix the same in l3fwd as "MAX_TX_QUEUE_PER_PORT" is redundant. I can submit a separate patch for l3fwd.
19/11/2025 14:56, Tummala, Sivaprasad:
Quoted 32 lines
From: Thomas Monjalon <[email protected]>
19/11/2025 13:08, Tummala, Sivaprasad:Quoted 30 lines
From: Thomas Monjalon <[email protected]>
06/10/2025 10:58, Tummala, Sivaprasad:Quoted 28 lines
From: Konstantin Ananyev <[email protected]>
Quoted 8 lines
Quoted 8 lines
Quoted 6 lines · Sivaprasad Tummala
examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have
Quoted 11 lines
#define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 9 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graph
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
Quoted 1 line
Why not applying the same change to both examples?
Yes, that's what the patch is intended for to fix l3fwd-graph and tx queues will scale with lcores and limited by
RTE_MAX_LCORES.But it is not done the same way.
Here you removeMAX_TX_QUEUE_PER_PORT.
Do you want to do the same in l3fwd?Yes, it's better to fix the same in l3fwd as "
MAX_TX_QUEUE_PER_PORT" is redundant. I can submit a separate patch for l3fwd.
Better to fix in a single patch.
Please check if there are similar issue in other examples.
[AMD Official Use Only - AMD Internal Distribution Only]
________________________________
From: Thomas Monjalon <[email protected]>
Sent: Wednesday, November 19, 2025 8:25 PM
To: Tummala, Sivaprasad <[email protected]>
Cc: Konstantin Ananyev <[email protected]>; Nithin Dabilpuram <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>; [email protected] <[email protected]>
Subject: Re: [PATCH] examples/l3fwd-graph: remove redundant Tx queue limit
Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
19/11/2025 14:56, Tummala, Sivaprasad:
Quoted 35 lines
Quoted 35 lines
From: Thomas Monjalon <[email protected]>
19/11/2025 13:08, Tummala, Sivaprasad:Quoted 32 lines
From: Thomas Monjalon <[email protected]>
06/10/2025 10:58, Tummala, Sivaprasad:Quoted 30 lines
From: Konstantin Ananyev <[email protected]>
Quoted 8 lines
Quoted 8 lines
Quoted 6 lines · Sivaprasad Tummala
examples/l3fwd-graph/main.c +0
-0@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024Quoted 6 lines
Quoted 2 lines
examples/l3fwd-graph/main.c line 52
Quoted 2 lines
examples/l3fwd-graph/main.c +0
-1-#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128AFAIK, in the mainline we actually have:
#defineMAX_TX_QUEUE_PER_PORTRTE_MAX_LCOREIn l3fwd-graph app, this change is not available and instead we have
Quoted 7 lines
#define
MAX_TX_QUEUE_PER_PORTRTE_MAX_ETHPORTSQuoted 5 lines
since:
commit88256ed85338c572d73006e4c4530a52d3b477ffAuthor: Harman Kalra <[email protected]> Date: Tue Jan 12 23:54:46 2021 +0530Quoted 6 lines
Quoted 4 lines
examples/l3fwd: remove limitation on Tx queue count
What I am missing here?
This patch marked here was fixing l3fwd app and not l3fwd-graphWhy not applying the same change to both examples?
Yes, that's what the patch is intended for to fix l3fwd-graph and tx queues will scale with lcores and limited by
RTE_MAX_LCORES.
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
But it is not done the same way.
Here you removeMAX_TX_QUEUE_PER_PORT.
Do you want to do the same in l3fwd?Yes, it's better to fix the same in l3fwd as "
MAX_TX_QUEUE_PER_PORT" is redundant. I can submit a separate patch for l3fwd.Better to fix in a single patch.
Please check if there are similar issue in other examples.
Sure, I will do the needful.
PATCH v2 1/5 examples/l3fwd-graph: remove redundant Tx queue limit
In reply to Sivaprasad TummalaIn l3fwd-graph application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/l3fwd-graph/main.c +0 -3
@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024 -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128#define MAX_RX_QUEUE_PER_LCORE 16
@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue);
Signature · 1 line
2.43.0
PATCH v2 2/5 examples/l3fwd: remove redundant Tx queue limit
In l3fwd application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/l3fwd/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/l3fwd/main.c +0 -3
@@ -49,7 +49,6 @@#include "l3fwd_event.h" #include "l3fwd_route.h" -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_LCORE#define MAX_RX_QUEUE_PER_PORT 128#define MAX_LCORE_PARAMS 1024
@@ -1341,8 +1340,6 @@ l3fwd_poll_resource_setup(void) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, (unsigned )n_tx_queue );
Signature · 1 line
2.43.0
PATCH v2 3/5 examples/ip_fragmentation: remove redundant Tx queue limit
In reply to Sivaprasad TummalaIn ip_fragmentation application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ip_fragmentation/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ip_fragmentation/main.c +0 -3
@@ -134,7 +134,6 @@ struct rx_queue { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16struct __rte_cache_aligned lcore_queue_conf {uint16_t n_rx_queue;uint16_t tx_queue_id[RTE_MAX_ETHPORTS ];
@@ -948,8 +947,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ; ret =rte_eth_dev_configure (portid,1 , (uint16_t )n_tx_queue, &local_port_conf);if (ret <0 ) {
Signature · 1 line
2.43.0
PATCH v2 4/5 examples/ip_reassembly: remove redundant Tx queue limit
In reply to Sivaprasad TummalaIn ip_reassembly application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ip_reassembly/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ip_reassembly/main.c +0 -3
@@ -145,7 +145,6 @@ struct tx_lcore_stat { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16#define MAX_RX_QUEUE_PER_PORT 128struct __rte_cache_aligned lcore_queue_conf {
@@ -1091,8 +1090,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;if (dev_info.tx_offload_capa &RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE ) local_port_conf.txmode.offloads |=RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE ;
Signature · 1 line
2.43.0
PATCH v2 5/5 examples/ipv4_multicast: remove redundant Tx queue limit
In reply to Sivaprasad TummalaIn ipv4_multicast application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ipv4_multicast/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ipv4_multicast/main.c +0 -3
@@ -97,7 +97,6 @@ struct mbuf_table { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16struct __rte_cache_aligned lcore_queue_conf {uint64_t tx_tsc;uint16_t n_rx_queue;
@@ -736,8 +735,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ; ret =rte_eth_dev_configure (portid,1 , (uint16_t )n_tx_queue, &local_port_conf);
Signature · 1 line
2.43.0
v3 cover examples: remove MAX_TX_QUEUE_PER_PORT
In reply to Sivaprasad TummalaThis is an old set of patches that removes the use of MAX_TX_QUEUE_PER_PORT in all the examples.
Sivaprasad Tummala (5):
examples/l3fwd-graph: remove redundant Tx queue limit examples/l3fwd: remove redundant Tx queue limit examples/ip_fragmentation: remove redundant Tx queue limit examples/ip_reassembly: remove redundant Tx queue limit examples/ipv4_multicast: remove redundant Tx queue limit
Stephen Hemminger (1):
examples: remove unused define
examples/ip_fragmentation/main.c | 3 --- examples/ip_reassembly/main.c | 3 --- examples/ipv4_multicast/main.c | 3 --- examples/l2fwd-crypto/main.c | 1 - examples/l2fwd-event/l2fwd_common.h | 1 - examples/l2fwd-jobstats/main.c | 1 - examples/l2fwd-keepalive/main.c | 1 - examples/l2fwd-macsec/main.c | 1 - examples/l2fwd/main.c | 2 +- examples/l3fwd-graph/main.c | 3 --- examples/l3fwd-power/main.c | 1 - examples/l3fwd/main.c | 3 --- examples/link_status_interrupt/main.c | 1 - 13 files changed, 1 insertion(+), 23 deletions(-)
Signature · 1 line
2.53.0
PATCH v3 1/6 examples/l3fwd-graph: remove redundant Tx queue limit
From: Sivaprasad Tummala <[email protected]>
In l3fwd-graph application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/l3fwd-graph/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/l3fwd-graph/main.c +0 -3
@@ -49,7 +49,6 @@#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024 -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128#define MAX_RX_QUEUE_PER_LCORE 16
@@ -1076,8 +1075,6 @@ main(int argc, char **argv) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, n_tx_queue);
Signature · 1 line
2.53.0
PATCH v3 2/6 examples/l3fwd: remove redundant Tx queue limit
In reply to Stephen HemmingerFrom: Sivaprasad Tummala <[email protected]>
In l3fwd application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_LCORE which is dead code.
--- examples/l3fwd/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/l3fwd/main.c +0 -3
@@ -48,7 +48,6 @@#include "l3fwd_event.h" #include "l3fwd_route.h" -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_LCORE#define MAX_RX_QUEUE_PER_PORT 128#define MAX_LCORE_PARAMS 1024
@@ -1373,8 +1372,6 @@ l3fwd_poll_resource_setup(void) nb_rx_queue =get_port_n_rx_queues (portid); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;printf ("Creating queues: nb_rxq=%d nb_txq=%u... " , nb_rx_queue, (unsigned )n_tx_queue );
Signature · 1 line
2.53.0
PATCH v3 3/6 examples/ip_fragmentation: remove redundant Tx queue limit
In reply to Stephen HemmingerFrom: Sivaprasad Tummala <[email protected]>
In ip_fragmentation application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ip_fragmentation/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ip_fragmentation/main.c +0 -3
@@ -133,7 +133,6 @@ struct rx_queue { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16struct __rte_cache_aligned lcore_queue_conf {uint16_t n_rx_queue;uint16_t tx_queue_id[RTE_MAX_ETHPORTS ];
@@ -947,8 +946,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ; ret =rte_eth_dev_configure (portid,1 , (uint16_t )n_tx_queue, &local_port_conf);if (ret <0 ) {
Signature · 1 line
2.53.0
PATCH v3 4/6 examples/ip_reassembly: remove redundant Tx queue limit
In reply to Stephen HemmingerFrom: Sivaprasad Tummala <[email protected]>
In ip_reassembly application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ip_reassembly/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ip_reassembly/main.c +0 -3
@@ -144,7 +144,6 @@ struct tx_lcore_stat { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16#define MAX_RX_QUEUE_PER_PORT 128struct __rte_cache_aligned lcore_queue_conf {
@@ -1097,8 +1096,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ;if (dev_info.tx_offload_capa &RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE ) local_port_conf.txmode.offloads |=RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE ;
Signature · 1 line
2.53.0
PATCH v3 5/6 examples/ipv4_multicast: remove redundant Tx queue limit
In reply to Stephen HemmingerFrom: Sivaprasad Tummala <[email protected]>
In ipv4_multicast application, Tx queues are configured per lcore to enable a lockless design and achieve optimal performance.
The MAX_TX_QUEUE_PER_PORT macro, defined as RTE_MAX_ETHPORTS, introduced an artificial constraint on the number of Tx queues and limited core-scaling performance.
This patch removes the unused MAX_TX_QUEUE_PER_PORT macro and redundant Tx queue check, allowing Tx queues to scale directly with the no. of lcores.
--- examples/ipv4_multicast/main.c | 3 --- 1 file changed, 3 deletions(-)
examples/ipv4_multicast/main.c +0 -3
@@ -96,7 +96,6 @@ struct mbuf_table { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16struct __rte_cache_aligned lcore_queue_conf {uint64_t tx_tsc;uint16_t n_rx_queue;
@@ -735,8 +734,6 @@ main(int argc, char **argv)fflush (stdout); n_tx_queue = nb_lcores; -if (n_tx_queue >MAX_TX_QUEUE_PER_PORT ) - n_tx_queue =MAX_TX_QUEUE_PER_PORT ; ret =rte_eth_dev_configure (portid,1 , (uint16_t )n_tx_queue, &local_port_conf);
Signature · 1 line
2.53.0
PATCH v3 6/6 examples: remove unused define
In reply to Stephen HemmingerThe #define MAX_TX_QUEUE_PER_PORT was copy/pasted across all the examples but never used.
--- examples/l2fwd-crypto/main.c | 1 - examples/l2fwd-event/l2fwd_common.h | 1 - examples/l2fwd-jobstats/main.c | 1 - examples/l2fwd-keepalive/main.c | 1 - examples/l2fwd-macsec/main.c | 1 - examples/l2fwd/main.c | 2 +- examples/l3fwd-power/main.c | 1 - examples/link_status_interrupt/main.c | 1 - 8 files changed, 1 insertion(+), 8 deletions(-)
examples/l2fwd-crypto/main.c +0 -1
@@ -100,7 +100,6 @@ struct op_buffer { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16enum l2fwd_crypto_xform_chain {L2FWD_CRYPTO_CIPHER_HASH ,
examples/l2fwd-event/l2fwd_common.h +0 -1
@@ -43,7 +43,6 @@#define MAX_PKT_BURST 32#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16#define RX_DESC_DEFAULT 1024#define TX_DESC_DEFAULT 1024
examples/l2fwd-jobstats/main.c +0 -1
@@ -64,7 +64,6 @@ static uint32_t l2fwd_dst_ports[RTE_MAX_ETHPORTS];static unsigned int l2fwd_rx_queue_per_lcore =1 ;#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16/* List of queues to be polled for given lcore. 8< */ struct __rte_cache_aligned lcore_queue_conf {unsigned n_rx_port;
examples/l2fwd-keepalive/main.c +0 -1
@@ -65,7 +65,6 @@ static uint32_t l2fwd_dst_ports[RTE_MAX_ETHPORTS];static unsigned int l2fwd_rx_queue_per_lcore =1 ;#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16struct __rte_cache_aligned lcore_queue_conf {unsigned n_rx_port;unsigned rx_port_list[MAX_RX_QUEUE_PER_LCORE ];
examples/l2fwd-macsec/main.c +0 -1
@@ -83,7 +83,6 @@ static uint16_t nb_port_pair_params;static unsigned int l2fwd_rx_queue_per_lcore =1 ;#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16/* List of queues to be polled for a given lcore. 8< */ struct __rte_cache_aligned lcore_queue_conf {unsigned int n_rx_port;
examples/l2fwd/main.c +1 -1
@@ -80,7 +80,7 @@ static uint16_t nb_port_pair_params;static unsigned int l2fwd_rx_queue_per_lcore =1 ;#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16 +/* List of queues to be polled for a given lcore. 8< */ struct __rte_cache_aligned lcore_queue_conf {unsigned n_rx_port;
examples/l3fwd-power/main.c +0 -1
@@ -221,7 +221,6 @@ struct __rte_cache_aligned lcore_rx_queue { };#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS#define MAX_RX_QUEUE_PER_PORT 128#define MAX_RX_QUEUE_INTERRUPT_PER_PORT 16
examples/link_status_interrupt/main.c +0 -1
@@ -63,7 +63,6 @@ static unsigned lsi_dst_ports[RTE_MAX_ETHPORTS] = {0};#define MAX_PKT_BURST 32#define MAX_RX_QUEUE_PER_LCORE 16 -#define MAX_TX_QUEUE_PER_PORT 16/* List of queues must be polled for a give lcore. 8< */ struct __rte_cache_aligned lcore_queue_conf {unsigned n_rx_port;
Signature · 1 line
2.53.0
Re: [PATCH v3 0/6] examples: remove MAX_TX_QUEUE_PER_PORT
In reply to Stephen HemmingerQuoted 13 lines · Stephen Hemminger
This is an old set of patches that removes the use of
MAX_TX_QUEUE_PER_PORTin all the examples.Sivaprasad Tummala (5):
examples/l3fwd-graph: remove redundant Tx queue limit examples/l3fwd: remove redundant Tx queue limit examples/ip_fragmentation: remove redundant Tx queue limit examples/ip_reassembly: remove redundant Tx queue limit examples/ipv4_multicast: remove redundant Tx queue limitStephen Hemminger (1):
examples: remove unused define
Quoted 15 lines
examples/ip_fragmentation/main.c | 3 --- examples/ip_reassembly/main.c | 3 --- examples/ipv4_multicast/main.c | 3 --- examples/l2fwd-crypto/main.c | 1 - examples/l2fwd-event/l2fwd_common.h | 1 - examples/l2fwd-jobstats/main.c | 1 - examples/l2fwd-keepalive/main.c | 1 - examples/l2fwd-macsec/main.c | 1 - examples/l2fwd/main.c | 2 +- examples/l3fwd-graph/main.c | 3 --- examples/l3fwd-power/main.c | 1 - examples/l3fwd/main.c | 3 --- examples/link_status_interrupt/main.c | 1 - 13 files changed, 1 insertion(+), 23 deletions(-)
Thomas Monjalon
AppliedRe: [PATCH v3 0/6] examples: remove MAX_TX_QUEUE_PER_PORT
26/06/2026 09:23, Bruce Richardson:
Quoted 11 lines · Stephen Hemminger
Quoted 10 lines
This is an old set of patches that removes the use of
MAX_TX_QUEUE_PER_PORTin all the examples.Sivaprasad Tummala (5):
examples/l3fwd-graph: remove redundant Tx queue limit examples/l3fwd: remove redundant Tx queue limit examples/ip_fragmentation: remove redundant Tx queue limit examples/ip_reassembly: remove redundant Tx queue limit examples/ipv4_multicast: remove redundant Tx queue limit
Quoted 4 lines
Quoted 3 lines
Stephen Hemminger (1):
examples: remove unused defineSeries-acked-by Bruce Richardson <[email protected]>
Applied, thanks.