CVE-2026-98179: drm/amdgpu: fix rmmio iounmap skipped on device removal
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
drm/amdgpu: fix rmmio iounmap skipped on device removal
amdgpu_pci_remove() calls drm_dev_unplug() before fini_sw(), so drm_dev_enter() is already false there and the iounmap() guarded by it is skipped. This .remove path runs on both hot-unplug and plain rmmod, so the register BAR ioremap mapping leaks one instance per unload.
Unmap rmmio unconditionally (guard only on non-NULL) and drop the now unused idx.
(cherry picked from commit dd6f86a97260e5207d3329ad03aa89fdad61b1e6)
The Linux kernel CVE team has assigned CVE-2026-98179 to this issue.
Affected and fixed versions
===========================
Issue introduced in 5.17 with commit 62d5f9f7110ad374db67ab4820f4ff2d916c3cdb and fixed in 6.12.112 with commit e81502d6791df9ecd003bfb2ca44f0d1f1b38439 Issue introduced in 5.17 with commit 62d5f9f7110ad374db67ab4820f4ff2d916c3cdb and fixed in 6.18.54 with commit cd55dde2b63789a3dafe982c89844f537501d096 Issue introduced in 5.17 with commit 62d5f9f7110ad374db67ab4820f4ff2d916c3cdb and fixed in 7.2.8 with commit a645584c3ccc493ee835f77155829442bd7578c3 Issue introduced in 5.17 with commit 62d5f9f7110ad374db67ab4820f4ff2d916c3cdb and fixed in 7.3-rc4 with commit 5155002b03b24ba3ef91c5c313b8cf0171b24904
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-98179
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/gpu/drm/amd/amdgpu/amdgpu_device.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/e81502d6791df9ecd003bfb2ca44f0d1f1b38439 https://git.kernel.org/stable/c/cd55dde2b63789a3dafe982c89844f537501d096 https://git.kernel.org/stable/c/a645584c3ccc493ee835f77155829442bd7578c3 https://git.kernel.org/stable/c/5155002b03b24ba3ef91c5c313b8cf0171b24904