CVE-2026-98226
mm, swap: fix SWAP_USAGE_OFFLIST_BIT collision with real usage count
Check your servers for CVE-2026-98226
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2026-98226 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
In the Linux kernel, the following vulnerability has been resolved:
mm, swap: fix SWAP_USAGE_OFFLIST_BIT collision with real usage count
SWAP_USAGE_OFFLIST_BIT is embedded in the si->inuse_pages usage counter, and is meant to sit above any value that counter can reach. However, it is defined from BITS_PER_TYPE(atomic_t), so it is bit 30. On a system with 4 KiB pages the flag collides with the usage count once that count reaches 4 TiB.
swap_usage_in_pages() masks bit 30 out, so whenever the real count has that bit set, every caller of it reads 4 TiB low:
* /proc/swaps understates Used by 4 TiB.
* A raw count of exactly 2^30 masks to zero, so try_to_unuse() takes its "if (!swap_usage_in_pages(si)) goto success;" early exit and swapoff tears the device down while pages are still swapped out. Nothing in the rest of swapoff aborts the teardown, so those pages are lost.
Independently of swapoff, the collision also corrupts the counter and the plist. On a device in normal use, a free that leaves bit 30 set in the count makes swap_usage_sub() see the flag where there is only count, and call add_to_avail_list(). It clears the bit with fetch_and(~SWAP_USAGE_OFFLIST_BIT), leaving the stored count 4 TiB below the real one, and calls plist_add() on a device that is already listed, tripping the WARN_ON(!plist_node_empty(node)) in plist_add() and linking the node a second time.
Change the definition of SWAP_USAGE_OFFLIST_BIT to be based on atomic_long_t instead. Note that the usage counter field itself is of this same type, so it is still a valid bit.
Exploitation
EPSS 0.21%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 6.00% of all scored CVEs. Scores of 30 Nov 2026.
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from b228386cf237e659cdf5d8037a19db0b0a06f6b5, before 0a41a46859df0d2bd7ed127197aac7c7389c00ed affected from b228386cf237e659cdf5d8037a19db0b0a06f6b5, before 7c0d0d6de46076b43a2acaf1026b6648f8434c39 affected from b228386cf237e659cdf5d8037a19db0b0a06f6b5, before 12e9ac7bc5b254048f886bf421e3a15491106c1f
Other versions: unaffected
|
| Linux |
affected 6.14 unaffected before 6.14 unaffected from 6.18.54 up to and including 6.18.* unaffected from 7.2.8 up to and including 7.2.* unaffected 7.3 and later
Other versions: affected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2026-98226 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2026-98226
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2026-98226
trivy image --scanners vuln IMAGE | grep CVE-2026-98226
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/0a41a46859df0d2bd7ed127197aac7c7389c00ed git.kernel.org
- https://git.kernel.org/stable/c/7c0d0d6de46076b43a2acaf1026b6648f8434c39 git.kernel.org
- https://git.kernel.org/stable/c/12e9ac7bc5b254048f886bf421e3a15491106c1f git.kernel.org
Source: the record CVE-2026-98226 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse