{"id":"CVE-2025-71221","summary":"dmaengine: mmp_pdma: Fix race condition in mmp_pdma_residue()","details":"In the Linux kernel, the following vulnerability has been resolved:\n\ndmaengine: mmp_pdma: Fix race condition in mmp_pdma_residue()\n\nAdd proper locking in mmp_pdma_residue() to prevent use-after-free when\naccessing descriptor list and descriptor contents.\n\nThe race occurs when multiple threads call tx_status() while the tasklet\non another CPU is freeing completed descriptors:\n\nCPU 0                              CPU 1\n-----                              -----\nmmp_pdma_tx_status()\nmmp_pdma_residue()\n  -\u003e NO LOCK held\n     list_for_each_entry(sw, ..)\n                                   DMA interrupt\n                                   dma_do_tasklet()\n                                     -\u003e spin_lock(&desc_lock)\n                                        list_move(sw-\u003enode, ...)\n                                        spin_unlock(&desc_lock)\n  |                                     dma_pool_free(sw) \u003c- FREED!\n  -\u003e access sw-\u003edesc \u003c- UAF!\n\nThis issue can be reproduced when running dmatest on the same channel with\nmultiple threads (threads_per_chan \u003e 1).\n\nFix by protecting the chain_running list iteration and descriptor access\nwith the chan-\u003edesc_lock spinlock.","modified":"2026-04-02T13:04:56.926577Z","published":"2026-02-14T16:27:04.631Z","related":["CGA-8g37-5f4r-5xwc"],"database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/71xxx/CVE-2025-71221.json","cna_assigner":"Linux"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/9f665b3c3d9a168410251f27a5d019b7bf93185c"},{"type":"WEB","url":"https://git.kernel.org/stable/c/a143545855bc2c6e1330f6f57ae375ac44af00a7"},{"type":"WEB","url":"https://git.kernel.org/stable/c/dfb5e05227745de43b7fd589721817a4337c970d"},{"type":"WEB","url":"https://git.kernel.org/stable/c/eba0c75670c022cb1f948600db972524bcfe8166"},{"type":"WEB","url":"https://git.kernel.org/stable/c/fc023b8fab057f0c910856ff36d3e12a30b7af4a"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/71xxx/CVE-2025-71221.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71221"},{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48"},{"fixed":"dfb5e05227745de43b7fd589721817a4337c970d"},{"fixed":"eba0c75670c022cb1f948600db972524bcfe8166"},{"fixed":"fc023b8fab057f0c910856ff36d3e12a30b7af4a"},{"fixed":"9f665b3c3d9a168410251f27a5d019b7bf93185c"},{"fixed":"a143545855bc2c6e1330f6f57ae375ac44af00a7"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-71221.json"}}],"schema_version":"1.7.5"}