[dpdk-stable] patch 'bus/vdev: fix multi-process IPC buffer leak on scan' has been queued to stable release 18.08.1
Kevin Traynor
ktraynor at redhat.com
Thu Nov 22 17:49:17 CET 2018
Hi,
FYI, your patch has been queued to stable release 18.08.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 11/28/18. 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. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.
Thanks.
Kevin Traynor
---
>From 88aa5129d0f25ce304affb506db3b7b9f29aac04 Mon Sep 17 00:00:00 2001
From: Paul Luse <paul.e.luse at intel.com>
Date: Fri, 21 Sep 2018 12:25:57 -0400
Subject: [PATCH] bus/vdev: fix multi-process IPC buffer leak on scan
[ upstream commit 66fd3a3b0f5be39ba30a2d6aa617604c8d221230 ]
This patch fixes an issue caught with ASAN where a vdev_scan()
to a secondary bus was failing to free some memory.
The doxygen comment in EAL is fixed at the same time.
Fixes: cdb068f031c6 ("bus/vdev: scan by multi-process channel")
Fixes: 783b6e54971d ("eal: add synchronous multi-process communication")
Signed-off-by: Paul Luse <paul.e.luse at intel.com>
Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit at intel.com>
---
drivers/bus/vdev/vdev.c | 1 +
lib/librte_eal/common/include/rte_eal.h | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/bus/vdev/vdev.c b/drivers/bus/vdev/vdev.c
index 69dee89a8..2566d6c0d 100644
--- a/drivers/bus/vdev/vdev.c
+++ b/drivers/bus/vdev/vdev.c
@@ -424,4 +424,5 @@ vdev_scan(void)
resp = (struct vdev_param *)mp_rep->param;
VDEV_LOG(INFO, "Received %d vdevs", resp->num);
+ free(mp_reply.msgs);
} else
VDEV_LOG(ERR, "Failed to request vdev from primary");
diff --git a/lib/librte_eal/common/include/rte_eal.h b/lib/librte_eal/common/include/rte_eal.h
index e114dcbdc..71a8518cc 100644
--- a/lib/librte_eal/common/include/rte_eal.h
+++ b/lib/librte_eal/common/include/rte_eal.h
@@ -317,5 +317,5 @@ rte_mp_sendmsg(struct rte_mp_msg *msg);
* @param reply
* The reply argument will be for storing all the replied messages;
- * the caller is responsible for free reply->replies.
+ * the caller is responsible for free reply->msgs.
*
* @param ts
--
2.19.0
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2018-11-22 16:47:32.916091650 +0000
+++ 0025-bus-vdev-fix-multi-process-IPC-buffer-leak-on-scan.patch 2018-11-22 16:47:32.000000000 +0000
@@ -1,8 +1,10 @@
-From 66fd3a3b0f5be39ba30a2d6aa617604c8d221230 Mon Sep 17 00:00:00 2001
+From 88aa5129d0f25ce304affb506db3b7b9f29aac04 Mon Sep 17 00:00:00 2001
From: Paul Luse <paul.e.luse at intel.com>
Date: Fri, 21 Sep 2018 12:25:57 -0400
Subject: [PATCH] bus/vdev: fix multi-process IPC buffer leak on scan
+[ upstream commit 66fd3a3b0f5be39ba30a2d6aa617604c8d221230 ]
+
This patch fixes an issue caught with ASAN where a vdev_scan()
to a secondary bus was failing to free some memory.
@@ -10,7 +12,6 @@
Fixes: cdb068f031c6 ("bus/vdev: scan by multi-process channel")
Fixes: 783b6e54971d ("eal: add synchronous multi-process communication")
-Cc: stable at dpdk.org
Signed-off-by: Paul Luse <paul.e.luse at intel.com>
Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
@@ -21,17 +22,17 @@
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/bus/vdev/vdev.c b/drivers/bus/vdev/vdev.c
-index 688e31c21..685cc4e78 100644
+index 69dee89a8..2566d6c0d 100644
--- a/drivers/bus/vdev/vdev.c
+++ b/drivers/bus/vdev/vdev.c
-@@ -426,4 +426,5 @@ vdev_scan(void)
+@@ -424,4 +424,5 @@ vdev_scan(void)
resp = (struct vdev_param *)mp_rep->param;
VDEV_LOG(INFO, "Received %d vdevs", resp->num);
+ free(mp_reply.msgs);
} else
VDEV_LOG(ERR, "Failed to request vdev from primary");
diff --git a/lib/librte_eal/common/include/rte_eal.h b/lib/librte_eal/common/include/rte_eal.h
-index 3ee897c1d..6514a9fe6 100644
+index e114dcbdc..71a8518cc 100644
--- a/lib/librte_eal/common/include/rte_eal.h
+++ b/lib/librte_eal/common/include/rte_eal.h
@@ -317,5 +317,5 @@ rte_mp_sendmsg(struct rte_mp_msg *msg);
More information about the stable
mailing list