patch 'net/nbl: fix use after freeing device' has been queued to stable release 25.11.5
Kevin Traynor
ktraynor at redhat.com
Thu Dec 3 13:59:31 CET 2026
Hi,
FYI, your patch has been queued to stable release 25.11.5
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/08/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/kevintraynor/dpdk-stable
This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/39fd2b4f4253f408655bacb5d72dc783f1080228
Thanks.
Kevin
---
>From 39fd2b4f4253f408655bacb5d72dc783f1080228 Mon Sep 17 00:00:00 2001
From: Anatoly Burakov <anatoly.burakov at intel.com>
Date: Thu, 27 Aug 2026 09:47:55 +0100
Subject: [PATCH] net/nbl: fix use after freeing device
[ upstream commit c2cf96ba2d37742a571c3ebc4a7fa0f30c3eabe2 ]
When unmapping a device, the device is not removed from TAILQ, which may
result in attempting to access this devices' data during subsequent mem
event callbacks (as they are only disabled once all devices are removed).
Remove the device from TAILQ on unmap to fix it, and move the device fd
close under the memcfg lock to avoid race between a mem event and fd close.
Fixes: dc955cd24c8f ("net/nbl: add coexistence mode")
Signed-off-by: Anatoly Burakov <anatoly.burakov at intel.com>
---
drivers/net/nbl/nbl_common/nbl_userdev.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/nbl/nbl_common/nbl_userdev.c b/drivers/net/nbl/nbl_common/nbl_userdev.c
index 96f0d2e264..ec6840d60e 100644
--- a/drivers/net/nbl/nbl_common/nbl_userdev.c
+++ b/drivers/net/nbl/nbl_common/nbl_userdev.c
@@ -548,6 +548,7 @@ static int nbl_mdev_unmap_device(struct nbl_adapter *adapter)
int vfio_group_fd, ret;
- close(common->devfd);
rte_mcfg_mem_read_lock();
+ TAILQ_REMOVE(&nbl_adapter_list, adapter, next);
+ close(common->devfd);
vfio_group_fd = rte_vfio_container_group_bind(nbl_default_container,
common->iommu_group_num);
--
2.56.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2026-12-03 12:52:40.611972871 +0000
+++ 0045-net-nbl-fix-use-after-freeing-device.patch 2026-12-03 12:52:39.045821885 +0000
@@ -1 +1 @@
-From c2cf96ba2d37742a571c3ebc4a7fa0f30c3eabe2 Mon Sep 17 00:00:00 2001
+From 39fd2b4f4253f408655bacb5d72dc783f1080228 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit c2cf96ba2d37742a571c3ebc4a7fa0f30c3eabe2 ]
+
@@ -14 +15,0 @@
-Cc: stable at dpdk.org
More information about the stable
mailing list