patch 'net/pcap: set live interface as non-blocking' has been queued to stable release 23.11.3

Xueming Li xuemingl at nvidia.com
Mon Nov 11 07:28:03 CET 2024


Hi,

FYI, your patch has been queued to stable release 23.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 11/30/24. 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://git.dpdk.org/dpdk-stable/log/?h=23.11-staging

This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=84123ec794ad3a8c2796fe344030ce8fb9c32e67

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 84123ec794ad3a8c2796fe344030ce8fb9c32e67 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen at networkplumber.org>
Date: Sat, 24 Aug 2024 11:07:10 -0700
Subject: [PATCH] net/pcap: set live interface as non-blocking
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit 60dd5a70035f447104d457aa338557fb58d5cb06 ]

The DPDK PMD's are supposed to be non-blocking and poll for packets.
Configure PCAP to do this on live interface.

Bugzilla ID: 1526
Fixes: 4c173302c307 ("pcap: add new driver")

Reported-by: Ofer Dagan <ofer.d at claroty.com>
Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
Acked-by: Ferruh Yigit <ferruh.yigit at amd.com>
---
 drivers/net/pcap/pcap_ethdev.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/net/pcap/pcap_ethdev.c b/drivers/net/pcap/pcap_ethdev.c
index 9626c343dc..1fb98e3d2b 100644
--- a/drivers/net/pcap/pcap_ethdev.c
+++ b/drivers/net/pcap/pcap_ethdev.c
@@ -522,6 +522,12 @@ open_iface_live(const char *iface, pcap_t **pcap) {
 		return -1;
 	}

+	if (pcap_setnonblock(*pcap, 1, errbuf)) {
+		PMD_LOG(ERR, "Couldn't set non-blocking on %s: %s", iface, errbuf);
+		pcap_close(*pcap);
+		return -1;
+	}
+
 	return 0;
 }

--
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-11-11 14:23:08.754897266 +0800
+++ 0077-net-pcap-set-live-interface-as-non-blocking.patch	2024-11-11 14:23:05.202192838 +0800
@@ -1 +1 @@
-From 60dd5a70035f447104d457aa338557fb58d5cb06 Mon Sep 17 00:00:00 2001
+From 84123ec794ad3a8c2796fe344030ce8fb9c32e67 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 60dd5a70035f447104d457aa338557fb58d5cb06 ]
@@ -11 +13,0 @@
-Cc: stable at dpdk.org


More information about the stable mailing list