[dpdk-stable] patch 'app/testpmd: verify DCB config during forward config' has been queued to stable release 20.11.2

Xueming Li xuemingl at nvidia.com
Sat Jun 12 01:02:27 CEST 2021


Hi,

FYI, your patch has been queued to stable release 20.11.2

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/14/21. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/steevenlee/dpdk

This queued commit can be viewed at:
https://github.com/steevenlee/dpdk/commit/1f6d0c6f6c460c8ed720cd5f198a191c09b864dd

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 1f6d0c6f6c460c8ed720cd5f198a191c09b864dd Mon Sep 17 00:00:00 2001
From: Huisong Li <lihuisong at huawei.com>
Date: Wed, 28 Apr 2021 14:40:44 +0800
Subject: [PATCH] app/testpmd: verify DCB config during forward config
Cc: Luca Boccassi <bluca at debian.org>

[ upstream commit 43f1f8261136852357057b78aa49d354beaf3931 ]

Currently, the check for doing DCB test is assigned to
start_packet_forwarding(), which will be called when
run "start" cmd. But fwd_config_setup() is used in many
scenarios, such as, "port config all rxq".

This patch moves the check from start_packet_forwarding()
to fwd_config_setup().

Fixes: 7741e4cf16c0 ("app/testpmd: VMDq and DCB updates")

Signed-off-by: Huisong Li <lihuisong at huawei.com>
Signed-off-by: Lijun Ou <oulijun at huawei.com>
Acked-by: Xiaoyun Li <xiaoyun.li at intel.com>
---
 app/test-pmd/config.c  | 23 +++++++++++++++++++++--
 app/test-pmd/testpmd.c | 19 -------------------
 2 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index 1397b31326..25c2340d74 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -3344,6 +3344,10 @@ icmp_echo_config_setup(void)
 void
 fwd_config_setup(void)
 {
+	struct rte_port *port;
+	portid_t pt_id;
+	unsigned int i;
+
 	cur_fwd_config.fwd_eng = cur_fwd_eng;
 	if (strcmp(cur_fwd_eng->fwd_mode_name, "icmpecho") == 0) {
 		icmp_echo_config_setup();
@@ -3351,9 +3355,24 @@ fwd_config_setup(void)
 	}
 
 	if ((nb_rxq > 1) && (nb_txq > 1)){
-		if (dcb_config)
+		if (dcb_config) {
+			for (i = 0; i < nb_fwd_ports; i++) {
+				pt_id = fwd_ports_ids[i];
+				port = &ports[pt_id];
+				if (!port->dcb_flag) {
+					printf("In DCB mode, all forwarding ports must "
+						"be configured in this mode.\n");
+					return;
+				}
+			}
+			if (nb_fwd_lcores == 1) {
+				printf("In DCB mode,the nb forwarding cores "
+					"should be larger than 1.\n");
+				return;
+			}
+
 			dcb_fwd_config_setup();
-		else
+		} else
 			rss_fwd_config_setup();
 	}
 	else
diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index a419929f52..d830fe3a2f 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -2120,9 +2120,7 @@ start_packet_forwarding(int with_tx_first)
 {
 	port_fwd_begin_t port_fwd_begin;
 	port_fwd_end_t  port_fwd_end;
-	struct rte_port *port;
 	unsigned int i;
-	portid_t   pt_id;
 
 	if (strcmp(cur_fwd_eng->fwd_mode_name, "rxonly") == 0 && !nb_rxq)
 		rte_exit(EXIT_FAILURE, "rxq are 0, cannot use rxonly fwd mode\n");
@@ -2145,23 +2143,6 @@ start_packet_forwarding(int with_tx_first)
 		printf("Packet forwarding already started\n");
 		return;
 	}
-
-	if (dcb_config) {
-		for (i = 0; i < nb_fwd_ports; i++) {
-			pt_id = fwd_ports_ids[i];
-			port = &ports[pt_id];
-			if (!port->dcb_flag) {
-				printf("In DCB mode, all forwarding ports must "
-                                       "be configured in this mode.\n");
-				return;
-			}
-		}
-		if (nb_fwd_lcores == 1) {
-			printf("In DCB mode,the nb forwarding cores "
-                               "should be larger than 1.\n");
-			return;
-		}
-	}
 	test_done = 0;
 
 	fwd_config_setup();
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-06-12 06:53:58.024893300 +0800
+++ 0053-app-testpmd-verify-DCB-config-during-forward-config.patch	2021-06-12 06:53:56.260000000 +0800
@@ -1 +1 @@
-From 43f1f8261136852357057b78aa49d354beaf3931 Mon Sep 17 00:00:00 2001
+From 1f6d0c6f6c460c8ed720cd5f198a191c09b864dd Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Luca Boccassi <bluca at debian.org>
+
+[ upstream commit 43f1f8261136852357057b78aa49d354beaf3931 ]
@@ -15 +17,0 @@
-Cc: stable at dpdk.org
@@ -26 +28 @@
-index bbf039de76..fc057e5687 100644
+index 1397b31326..25c2340d74 100644
@@ -29 +31 @@
-@@ -3199,6 +3199,10 @@ icmp_echo_config_setup(void)
+@@ -3344,6 +3344,10 @@ icmp_echo_config_setup(void)
@@ -40 +42 @@
-@@ -3206,9 +3210,24 @@ fwd_config_setup(void)
+@@ -3351,9 +3355,24 @@ fwd_config_setup(void)
@@ -68 +70 @@
-index a076b1dcde..abcbdaa6e1 100644
+index a419929f52..d830fe3a2f 100644
@@ -71 +73 @@
-@@ -2138,9 +2138,7 @@ start_packet_forwarding(int with_tx_first)
+@@ -2120,9 +2120,7 @@ start_packet_forwarding(int with_tx_first)
@@ -81 +83 @@
-@@ -2163,23 +2161,6 @@ start_packet_forwarding(int with_tx_first)
+@@ -2145,23 +2143,6 @@ start_packet_forwarding(int with_tx_first)


More information about the stable mailing list