Skip to contentSkip to conversation

CVE-2026-72474: dmaengine: dma-axi-dmac: use DMA pool to manange DMA descriptor

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Aug 15

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

dmaengine: dma-axi-dmac: use DMA pool to manange DMA descriptor

For architectures like Microblaze or arm64 (where this IP is used), DMA_DIRECT_REMAP is set which means that dma_alloc_coherent() might remap (and hence vmalloc()) some memory. This became visible in a design where dma_direct_use_pool() is not possible.

With the above, when calling dma_free_coherent(), vunmap() would be called from softirq context and thus leading to a BUG().

To fix it, use a dma pool that is allocated in .device_alloc_chan_resources() and allocate blocks from it. The key point is that now dma_pool_free() is used in axi_dmac_free_desc() to free the blocks and that just frees the blocks from the pool in the sense they can be used again. In other words, no actual call to dma_free_coherent() happens. That only happens when destroying the pool in axi_dmac_free_chan_resources() which does not happen in any interrupt context.

The Linux kernel CVE team has assigned CVE-2026-72474 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 6.8 with commit 3f8fd25936ee5f52596f10d420f650c5b5e3285f and fixed in 6.12.97 with commit a4f41ceecfe68e117bae9c76c5ebc5e2b353fa56
	Issue introduced in 6.8 with commit 3f8fd25936ee5f52596f10d420f650c5b5e3285f and fixed in 6.18.40 with commit c0e6bb2b0408fcac6382158ee2bd9fdc45eceee9
	Issue introduced in 6.8 with commit 3f8fd25936ee5f52596f10d420f650c5b5e3285f and fixed in 7.1.5 with commit 65e82fa24965b2eb6ad9412f6c530ed9a50a625f
	Issue introduced in 6.8 with commit 3f8fd25936ee5f52596f10d420f650c5b5e3285f and fixed in 7.2-rc1 with commit 9e942c8579130e62734c14338e9f451780669164

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-72474

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
drivers/dma/dma-axi-dmac.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/a4f41ceecfe68e117bae9c76c5ebc5e2b353fa56
	https://git.kernel.org/stable/c/c0e6bb2b0408fcac6382158ee2bd9fdc45eceee9
	https://git.kernel.org/stable/c/65e82fa24965b2eb6ad9412f6c530ed9a50a625f
	https://git.kernel.org/stable/c/9e942c8579130e62734c14338e9f451780669164