{"id":"CVE-2025-71221","aliases":["CVE-2025-71221"],"related":[],"kind":"vulnerability","state":"published","title":"dmaengine: mmp_pdma: Fix race condition in mmp_pdma_residue()","summary":"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  -> NO LOCK held\n     list_for_each_entry(sw, ..)\n                                   DMA interrupt\n                                   dma_do_tasklet()\n                                     -> spin_lock(&desc_lock)\n                                        list_move(sw->node, ...)\n                                        spin_unlock(&desc_lock)\n  |                                     dma_pool_free(sw) <- FREED!\n  -> access sw->desc <- UAF!\n\nThis issue can be reproduced when running dmatest on the same channel with\nmultiple threads (threads_per_chan > 1).\n\nFix by protecting the chain_running list iteration and descriptor access\nwith the chan->desc_lock spinlock.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"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  -> NO LOCK held\n     list_for_each_entry(sw, ..)\n                                   DMA interrupt\n                                   dma_do_tasklet()\n                                     -> spin_lock(&desc_lock)\n                                        list_move(sw->node, ...)\n                                        spin_unlock(&desc_lock)\n  |                                     dma_pool_free(sw) <- FREED!\n  -> access sw->desc <- UAF!\n\nThis issue can be reproduced when running dmatest on the same channel with\nmultiple threads (threads_per_chan > 1).\n\nFix by protecting the chain_running list iteration and descriptor access\nwith the chan->desc_lock spinlock.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\ndmaengine: mmp_pdma: Corrección de condición de carrera en mmp_pdma_residue()\n\nAñadir bloqueo adecuado en mmp_pdma_residue() para prevenir uso después de liberación al acceder a la lista de descriptores y al contenido del descriptor.\n\nLa condición de carrera ocurre cuando múltiples hilos llaman a tx_status() mientras el tasklet en otra CPU está liberando descriptores completados:\n\nCPU 0                              CPU 1\n-----                              -----\nmmp_pdma_tx_status()\nmmp_pdma_residue()\n  -&gt; SIN BLOQUEO mantenido\n     list_for_each_entry(sw, ..)\n                                   Interrupción DMA\n                                   dma_do_tasklet()\n                                     -&gt; spin_lock(&amp;desc_lock)\n                                        list_move(sw-&gt;node, ...)\n                                        spin_unlock(&amp;desc_lock)\n  |                                     dma_pool_free(sw) &lt;- ¡LIBERADO!\n  -&gt; acceso a sw-&gt;desc &lt;- ¡UAF!\n\nEste problema puede ser reproducido al ejecutar dmatest en el mismo canal con múltiples hilos (hilos_por_canal &gt; 1).\n\nSolución protegiendo la iteración de la lista chain_running y el acceso al descriptor con el spinlock chan-&gt;desc_lock.","source":"nvd"}],"published":"2026-02-14T16:27:04.631Z","modified":"2026-11-10T13:18:08.930Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7,"rating":"HIGH"}],"cwes":["CWE-362"],"affected":[{"ranges":[{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"3f0e0e2d9e752570041e95fd04635e2580097819","status":"affected"},{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"dfb5e05227745de43b7fd589721817a4337c970d","status":"affected"},{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"eba0c75670c022cb1f948600db972524bcfe8166","status":"affected"},{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"fc023b8fab057f0c910856ff36d3e12a30b7af4a","status":"affected"},{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"9f665b3c3d9a168410251f27a5d019b7bf93185c","status":"affected"},{"type":"git","introduced":"1b38da264674d6a0fe26a63996b8f88b88c3da48","fixed":"a143545855bc2c6e1330f6f57ae375ac44af00a7","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"3.16","status":"affected"},{"type":"semver","introduced":"0","fixed":"3.16","status":"unaffected"},{"type":"semver","introduced":"5.15.209","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.1.167","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.130","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.78","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.10","lastAffected":"6.18.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.19","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"3.16","fixed":"6.18.10"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"},{"status":"affected","version":"6.19"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/3f0e0e2d9e752570041e95fd04635e2580097819","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/dfb5e05227745de43b7fd589721817a4337c970d","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/eba0c75670c022cb1f948600db972524bcfe8166","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/fc023b8fab057f0c910856ff36d3e12a30b7af4a","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/9f665b3c3d9a168410251f27a5d019b7bf93185c","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/a143545855bc2c6e1330f6f57ae375ac44af00a7","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-082556.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-019113.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-457936.html","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-71221","url":"https://www.cve.org/CVERecord?id=CVE-2025-71221","licence":"CVE Terms of Use","modified":"2026-11-10T12:39:37.538Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-71221","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71221","licence":"Public domain","modified":"2026-11-10T13:18:08.930Z"}],"updatedAt":"2026-11-25T22:59:11.192Z","epss":{"score":0.0014,"percentile":0.03539,"date":"2026-12-01T12:00:22.000Z"}}