CVE-2026-143336: vdpa_sim: serialize IOTLB updates with dataplane access
In the Linux kernel, the following vulnerability has been resolved:
vdpasim: serialize IOTLB updates with dataplane access
The simulator translates IOTLB entries into iovecs or bvecs under iommulock, then drops the lock before copying data. A concurrent DMA unmap can delete the mapping and release its pinned backing pages while the copy is still in progress, leading to a UAF in copyfromiter().
Use the existing simulator mutex to serialize DMA map changes with the full backend work function. Also make vhost-vdpa stop device access before unpinning the backing pages. Otherwise, waiting in the simulator DMA unmap callback happens after the pages have already been released and cannot protect their lifetime.
Keep iommulock for the IOTLB table itself and avoid adding a second long-lived lock to the simulator.
I found this bug myself, though the patch was written with AI assistance.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.12.120 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.18.66 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 7.3.7
Event History
Frequently Asked Questions
What conditions are required to trigger this issue?
The issue requires concurrent dataplane copying and DMA unmapping in the vdpa_sim path. The unmap can remove an IOTLB mapping and release pinned backing pages after the copy operation has obtained iovecs or bvecs but before it finishes using them.
What is the impact of a successful race?
The race can cause a use-after-free in _copy_from_iter() when the backend copy continues after its backing pages have been released.
What mitigates the issue if an update cannot be applied immediately?
The provided data identifies the vulnerable condition as concurrent DMA map changes and dataplane access in vdpa_sim, but does not specify a supported workaround. Reducing or avoiding such concurrent activity would address the described race condition, though no configuration-level mitigation is provided.
How does the fix prevent the use-after-free?
The fix uses the existing simulator mutex to serialize DMA map changes with the full backend work function. It also makes vhost-vdpa stop device access before unpinning backing pages, ensuring pages remain valid while backend copying is in progress.