patch 'mempool/dpaa: fix use-after-free during pool cleanup' has been queued to stable release 24.11.9

luca.boccassi at gmail.com luca.boccassi at gmail.com
Thu Nov 5 17:42:40 CET 2026


Hi,

FYI, your patch has been queued to stable release 24.11.9

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/07/26. 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/4f23d0b111ad6d370704a77d7454b9ebcec98d9c

Thanks.

Luca Boccassi

---
>From 4f23d0b111ad6d370704a77d7454b9ebcec98d9c Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal at nxp.com>
Date: Fri, 16 Oct 2026 16:49:40 +0530
Subject: [PATCH] mempool/dpaa: fix use-after-free during pool cleanup

[ upstream commit 67cbab0ab30e259665373d0cc1682aa0ecd836cd ]

dpaa_mbuf_free_pool() freed the pool private data and then wrote to it:

	rte_free(mp->pool_data);
	bp_info->bp = NULL;

bp_info is DPAA_MEMPOOL_TO_POOL_INFO(mp), which is mp->pool_data, so
both refer to the same allocation. Clearing bp_info->bp after the
rte_free() writes into freed memory.

Clear the field before releasing the allocation, and free bp_info
directly rather than the alias.

Fixes: 376fb49ecfca ("net/dpaa: prevent multiple mempool config")

Signed-off-by: Hemant Agrawal <hemant.agrawal at nxp.com>
---
 drivers/mempool/dpaa/dpaa_mempool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mempool/dpaa/dpaa_mempool.c b/drivers/mempool/dpaa/dpaa_mempool.c
index 74bfcab509c..2bdbcd4c3fe 100644
--- a/drivers/mempool/dpaa/dpaa_mempool.c
+++ b/drivers/mempool/dpaa/dpaa_mempool.c
@@ -148,8 +148,8 @@ dpaa_mbuf_free_pool(struct rte_mempool *mp)
 		bman_free_pool(bp_info->bp);
 		DPAA_MEMPOOL_INFO("BMAN pool freed for bpid =%d",
 				  bp_info->bpid);
-		rte_free(mp->pool_data);
 		bp_info->bp = NULL;
+		rte_free(bp_info);
 		mp->pool_data = NULL;
 	}
 }
-- 
2.47.3

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2026-11-05 16:42:47.751438679 +0000
+++ 0073-mempool-dpaa-fix-use-after-free-during-pool-cleanup.patch	2026-11-05 16:42:45.005063297 +0000
@@ -1 +1 @@
-From 67cbab0ab30e259665373d0cc1682aa0ecd836cd Mon Sep 17 00:00:00 2001
+From 4f23d0b111ad6d370704a77d7454b9ebcec98d9c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 67cbab0ab30e259665373d0cc1682aa0ecd836cd ]
+
@@ -19 +20,0 @@
-Cc: stable at dpdk.org
@@ -27 +28 @@
-index 2f8555a026..94aea5e77c 100644
+index 74bfcab509c..2bdbcd4c3fe 100644
@@ -30 +31 @@
-@@ -143,8 +143,8 @@ dpaa_mbuf_free_pool(struct rte_mempool *mp)
+@@ -148,8 +148,8 @@ dpaa_mbuf_free_pool(struct rte_mempool *mp)


More information about the stable mailing list