patch 'eal: fix MP socket cleanup' has been queued to stable release 22.11.11
luca.boccassi at gmail.com
luca.boccassi at gmail.com
Mon Oct 27 17:19:07 CET 2025
Hi,
FYI, your patch has been queued to stable release 22.11.11
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 10/29/25. 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/bluca/dpdk-stable
This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/039a4ac228e9a844bcc8bf3e078684f04078e3e5
Thanks.
Luca Boccassi
---
>From 039a4ac228e9a844bcc8bf3e078684f04078e3e5 Mon Sep 17 00:00:00 2001
From: Yang Ming <mosesyyoung at gmail.com>
Date: Sat, 19 Jul 2025 23:32:25 +0800
Subject: [PATCH] eal: fix MP socket cleanup
[ upstream commit 4bc53f8f0d64ceba6c4077aa31229f1e38e0d30f ]
The secondary process should not close socket file for MP
channel before performing MP request synchronization.
This prevents error logs when the secondary process exits
without any operation on the crypto device while the primary
process starts the device.
Case situation:
eal_bus_cleanup has been added in rte_eal_cleanup. But for the
secondary process, rte_eal_cleanup firstly performs
rte_mp_channel_cleanup, which closes socket file for the MP
channel, making mp_fd invalid. Subsequently, eal_bus_cleanup
triggers vdev_cleanup, which calls mp_request_sync to send a
message via the MP channel. Since mp_fd is invalid, error logs
occur.
Error logs occur as below when the secondary process exit:
EAL: failed to send to (/tmp/dpdk/l2hicu/mp_socket) due to Bad
file descriptor
EAL: Fail to send request /tmp/dpdk/l2hicu/mp_socket:
ipsec_mb_mp_msg
USER1: Create MR request to primary process failed.
Function call trace:
1. rte_eal_cleanup->rte_mp_channel_cleanup->close_socket_fd
2. rte_eal_cleanup->eal_bus_cleanup->vdev_cleanup->
rte_vdev_driver->ipsec_mb_remove->ipsec_mb_qp_release->
ipsec_mb_secondary_qp_op->rte_mp_request_sync->mp_request_sync->
send_msg->sendmsg(mp_fd, &msgh, 0);
Fixes: 1cab1a40ea9b ("bus: cleanup devices on shutdown")
Signed-off-by: Yang Ming <mosesyyoung at gmail.com>
Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
---
lib/eal/freebsd/eal.c | 2 +-
lib/eal/linux/eal.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/eal/freebsd/eal.c b/lib/eal/freebsd/eal.c
index aa9f85c647..3da8dec76a 100644
--- a/lib/eal/freebsd/eal.c
+++ b/lib/eal/freebsd/eal.c
@@ -906,8 +906,8 @@ rte_eal_cleanup(void)
struct internal_config *internal_conf =
eal_get_internal_configuration();
rte_service_finalize();
- rte_mp_channel_cleanup();
eal_bus_cleanup();
+ rte_mp_channel_cleanup();
rte_eal_alarm_cleanup();
rte_trace_save();
eal_trace_fini();
diff --git a/lib/eal/linux/eal.c b/lib/eal/linux/eal.c
index 9f9a03bcf7..de30e521bd 100644
--- a/lib/eal/linux/eal.c
+++ b/lib/eal/linux/eal.c
@@ -1378,11 +1378,11 @@ rte_eal_cleanup(void)
rte_memseg_walk(mark_freeable, NULL);
rte_service_finalize();
+ eal_bus_cleanup();
#ifdef VFIO_PRESENT
vfio_mp_sync_cleanup();
#endif
rte_mp_channel_cleanup();
- eal_bus_cleanup();
rte_eal_alarm_cleanup();
rte_trace_save();
eal_trace_fini();
--
2.47.3
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-10-27 15:54:35.944878334 +0000
+++ 0029-eal-fix-MP-socket-cleanup.patch 2025-10-27 15:54:34.803949751 +0000
@@ -1 +1 @@
-From 4bc53f8f0d64ceba6c4077aa31229f1e38e0d30f Mon Sep 17 00:00:00 2001
+From 039a4ac228e9a844bcc8bf3e078684f04078e3e5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4bc53f8f0d64ceba6c4077aa31229f1e38e0d30f ]
+
@@ -36 +37,0 @@
-Cc: stable at dpdk.org
@@ -46 +47 @@
-index 0f957919d3..1804b4cfd2 100644
+index aa9f85c647..3da8dec76a 100644
@@ -49 +50 @@
-@@ -909,8 +909,8 @@ rte_eal_cleanup(void)
+@@ -906,8 +906,8 @@ rte_eal_cleanup(void)
@@ -60 +61 @@
-index 3a0c9c9db6..caf22033d0 100644
+index 9f9a03bcf7..de30e521bd 100644
@@ -63 +64 @@
-@@ -1333,11 +1333,11 @@ rte_eal_cleanup(void)
+@@ -1378,11 +1378,11 @@ rte_eal_cleanup(void)
More information about the stable
mailing list