[dpdk-stable] patch 'app/testpmd: fix invalid port detaching' has been queued to LTS release 18.11.6

Kevin Traynor ktraynor at redhat.com
Wed Dec 11 22:26:37 CET 2019


Hi,

FYI, your patch has been queued to LTS release 18.11.6

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/17/19. 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/kevintraynor/dpdk-stable-queue

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable-queue/commit/df025f644116d26700756b3cc5381b33a305f31a

Thanks.

Kevin.

---
>From df025f644116d26700756b3cc5381b33a305f31a Mon Sep 17 00:00:00 2001
From: Matan Azrad <matan at mellanox.com>
Date: Tue, 12 Nov 2019 08:47:39 +0000
Subject: [PATCH] app/testpmd: fix invalid port detaching

[ upstream commit 43d0e304980a1527bcac92dc679057b189e2545a ]

The port was not validated before detaching.

Ignore port detach operation when the port is not valid.

Fixes: f8e5baa2662d ("app/testpmd: check not detaching device twice")

Signed-off-by: Matan Azrad <matan at mellanox.com>
Acked-by: Bernard Iremonger <bernard.iremonger at intel.com>
---
 app/test-pmd/testpmd.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index 81f6d4f96..98fe2f8f7 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -2351,4 +2351,7 @@ detach_port_device(portid_t port_id)
 	printf("Removing a device...\n");
 
+	if (port_id_is_invalid(port_id, ENABLED_WARN))
+		return;
+
 	dev = rte_eth_devices[port_id].device;
 	if (dev == NULL) {
-- 
2.21.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-12-11 21:24:16.282476537 +0000
+++ 0045-app-testpmd-fix-invalid-port-detaching.patch	2019-12-11 21:24:12.704650453 +0000
@@ -1 +1 @@
-From 43d0e304980a1527bcac92dc679057b189e2545a Mon Sep 17 00:00:00 2001
+From df025f644116d26700756b3cc5381b33a305f31a Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 43d0e304980a1527bcac92dc679057b189e2545a ]
+
@@ -11 +12,0 @@
-Cc: stable at dpdk.org
@@ -20 +21 @@
-index 446da3623..73ebf37aa 100644
+index 81f6d4f96..98fe2f8f7 100644
@@ -23 +24 @@
-@@ -2558,4 +2558,7 @@ detach_port_device(portid_t port_id)
+@@ -2351,4 +2351,7 @@ detach_port_device(portid_t port_id)



More information about the stable mailing list