# CVE-2026-98166: drm/ttm: fix swapped-out resources never leaving their bulk\_move range

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.17% (percentile 4, 2026-11-26)
- **Published:** 2026-10-06T08:44:11.927Z
- **Modified:** 2026-10-26T16:17:23.973Z

## Who should check

- Anyone running Linux \>= 060f8f3020516d71bc4d6159d4d0beef85606a74, \< b48ebe399b4e72baa323462580fdd83ebda561e1; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 3db7d7d583419f7b1f2e141e36418802dbb25cf8; 0124a09e3e5f5f6080efe9663b27af27933f8382; \>= 6.18.57, \< 6.18.59; \>= 7.0.10, \< 7.1
- Anyone running Linux 7.1

## Description

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

drm/ttm: fix swapped-out resources never leaving their bulk\_move range

ttm\_tt\_swapout() returns the number of pages swapped out on success and
a negative error code on failure; for a populated ttm it never returns
zero. Commit b2ed01e7ad3d ("drm/ttm: Fix ttm\_bo\_swapout() infinite LRU
walk on swapout failure") moved the bulk\_move bookkeeping in
ttm\_bo\_swapout\_cb() under "if (!ret)", so the
ttm\_resource\_del\_bulk\_move\_unevictable() / ttm\_resource\_move\_to\_lru\_tail()
pair is now skipped on every successful swapout. The equivalent change
for the shrinker in commit 1d59f36e95f7 ("drm/ttm: Fix ttm\_bo\_shrink()
infinite LRU walk on backup failure") tests "lret \> 0", which is what
was intended here as well.

Before b2ed01e7ad3d the resource was taken off the bulk\_move before the
swapout; since then a swapped-out resource stays inside its BO's
bulk\_move range (and on the manager LRU) although it is unevictable.
When it is later freed or the BO leaves the bulk\_move
(ttm\_resource\_free(), ttm\_bo\_set\_bulk\_move() via amdgpu\_vm\_bo\_del()),
ttm\_resource\_del\_bulk\_move() skips it because of its
!ttm\_resource\_unevictable() guard, so a range endpoint in pos-\>first /
pos-\>last is left pointing at freed memory. The next
ttm\_lru\_bulk\_move\_tail() or ttm\_resource\_add\_bulk\_move() on that cursor
is a use-after-free, seen as the resv WARN in ttm\_lru\_bulk\_move\_add(),
"list\_del corruption" in ttm\_resource\_move\_to\_lru\_tail() or a NULL
dereference in ttm\_resource\_manager\_next() -- minutes to hours after a
hibernation, or at process exit / reboot following one. Samuel
Ainsworth's analysis of drm/amd issue 5387 (see Link) identified the
dangling cursor; the missing removal at swapout time is the reason it
dangles.

Testing the condition for success restores the removal. On an AMD
Phoenix APU (ASUS UM3406GA, gfx1103) running suspend-then-hibernate on
a 7.0.y stable kernel carrying the backport (Ubuntu 7.0.0-31) the bug
crashed 5 of 18 hibernation cycles; a function profile of one
hibernation showed 336 ttm\_tt\_swapout() calls and zero
ttm\_resource\_del\_bulk\_move\_unevictable() calls. With this change the
removal happens for every swapped-out resource and 12 further cycles
were clean.

## Affected and fixed versions

- Linux: \>= 060f8f3020516d71bc4d6159d4d0beef85606a74, \< b48ebe399b4e72baa323462580fdd83ebda561e1; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 3db7d7d583419f7b1f2e141e36418802dbb25cf8; 0124a09e3e5f5f6080efe9663b27af27933f8382; \>= 6.18.57, \< 6.18.59; \>= 7.0.10, \< 7.1 (cvelist)
- Linux: 7.1 (cvelist)

## Mitigation

- Upgrade Linux to 7.1 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-98166. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-98166.md
Affected: Linux >= 060f8f3020516d71bc4d6159d4d0beef85606a74, < b48ebe399b4e72baa323462580fdd83ebda561e1; >= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, < 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0; >= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, < 3db7d7d583419f7b1f2e141e36418802dbb25cf8; 0124a09e3e5f5f6080efe9663b…
Fixed in: Linux 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0, Linux 3db7d7d583419f7b1f2e141e36418802dbb25cf8, Linux 6.18.59, Linux 7.1

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-98166 being exploited?

There is no confirmed exploitation: CVE-2026-98166 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.17% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-98166?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-98166?

Linux \>= 060f8f3020516d71bc4d6159d4d0beef85606a74, \< b48ebe399b4e72baa323462580fdd83ebda561e1; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0; \>= b2ed01e7ad3de80333e9b962a44024b094bc0b2b, \< 3db7d7d583419f7b1f2e141e36418802dbb25cf8; 0124a09e3e5f5f6080efe9663b27af27933f8382; \>= 6.18.57, \< 6.18.59; \>= 7.0.10, \< 7.1; Linux 7.1.

### Is there a fix for CVE-2026-98166?

Yes. Fixed in Linux 1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0, Linux 3db7d7d583419f7b1f2e141e36418802dbb25cf8, Linux 6.18.59, Linux 7.1. Upgrade Linux to 7.1 or later.

### How do I check if I'm affected by CVE-2026-98166?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- other: <https://git.kernel.org/stable/c/b48ebe399b4e72baa323462580fdd83ebda561e1>
- other: <https://git.kernel.org/stable/c/1169fe8c11ca45e3f91d59a73eb271d0ca8a7fb0>
- other: <https://git.kernel.org/stable/c/3db7d7d583419f7b1f2e141e36418802dbb25cf8>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-98166>

HTML: <https://flawdb.com/CVE-2026-98166> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-98166>
