CVE-2026-143185: Xen/gnttab: improve error handling in gnttab_dma_{alloc,free}_pages()
In the Linux kernel, the following vulnerability has been resolved:
Xen/gnttab: improve error handling in gnttabdma{alloc,free}pages()
Both decrease-reservation and populate-physmap can succeed partially. For the former this may be pretty unlikely, but clearly the latter can hit both out-of-memory conditions in the hypervisor or denial because of the allocation exceeding the domain's allowance (there's no interaction with the balloon driver here either).
In gnttabdmafreepages() we simply can't give back to the system what hasn't been re-filled with backing memory. For gnttabdmaallocpages() both parts of the overall region need dealing with differently.
While no present caller of gnttabdmafreepages() checks its return value, also don't use -EFAULT there: It really is an out-of-memory condition. (In gnttabdmaallocpages() -EFAULT doesn't look quite right either, but I couldn't think of a clearly better error code there.)
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 5.10.276 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 5.15.227 - 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
Which systems are exposed to this issue?
Linux kernel systems using the Xen grant-table DMA page allocation and free paths are relevant. The issue concerns partial completion of Xen decrease-reservation and populate-physmap operations.
What conditions can trigger the faulty error handling?
Populate-physmap can complete only partially when the hypervisor is out of memory or rejects an allocation that exceeds the domain's allowance. Decrease-reservation can also partially succeed, although the description notes this is likely uncommon.
What is the operational impact of a partial operation?
During free, the kernel must not return memory to the system unless that memory has been refilled with backing pages. During allocation, the portions of the requested region that were handled differently by partially completed operations must receive separate cleanup handling.