patch 'app/dumpcap: check for failure to set promiscuous' has been queued to stable release 21.11.1

Kevin Traynor ktraynor at redhat.com
Tue Mar 8 15:14:58 CET 2022


Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/14/22. 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

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

Thanks.

Kevin

---
>From 8cac3f5d66cc79047967cd83148e6d569848fd9d Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen at networkplumber.org>
Date: Thu, 10 Feb 2022 15:09:06 -0800
Subject: [PATCH] app/dumpcap: check for failure to set promiscuous

[ upstream commit 499b1cbcf9d376a1130550ee61461276c5138a1b ]

If the rte_eth_promiscuous_enable() fails, then log the error
and continue.

Coverity issue: 373662
Fixes: cbb44143be74 ("app/dumpcap: add new packet capture application")

Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
---
 app/dumpcap/main.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/app/dumpcap/main.c b/app/dumpcap/main.c
index c5fe440302..536ec64711 100644
--- a/app/dumpcap/main.c
+++ b/app/dumpcap/main.c
@@ -680,6 +680,11 @@ static void enable_pdump(struct rte_ring *r, struct rte_mempool *mp)
 
 	TAILQ_FOREACH(intf, &interfaces, next) {
-		if (promiscuous_mode)
-			rte_eth_promiscuous_enable(intf->port);
+		if (promiscuous_mode) {
+			ret = rte_eth_promiscuous_enable(intf->port);
+			if (ret != 0)
+				fprintf(stderr,
+					"port %u set promiscuous enable failed: %d\n",
+					intf->port, ret);
+		}
 
 		ret = rte_pdump_enable_bpf(intf->port, RTE_PDUMP_ALL_QUEUES,
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-08 13:55:29.427085544 +0000
+++ 0043-app-dumpcap-check-for-failure-to-set-promiscuous.patch	2022-03-08 13:55:28.514315213 +0000
@@ -1 +1 @@
-From 499b1cbcf9d376a1130550ee61461276c5138a1b Mon Sep 17 00:00:00 2001
+From 8cac3f5d66cc79047967cd83148e6d569848fd9d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 499b1cbcf9d376a1130550ee61461276c5138a1b ]
+
@@ -11 +12,0 @@
-Cc: stable at dpdk.org



More information about the stable mailing list