CVE-2026-99918
publishedmm/madvise: atomically clear the young bit on THP MADV_COLD
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Linux | — | Linux9c276cc65a58faf98be8e56962745ec99ab87636 to < 9eeed293486a5389bc07232613ed57e875c5bdd8 · 9c276cc65a58faf98be8e56962745ec99ab87636 to < 17ee2edd085250973eb00cbd98c8b2e0f1a64eda · 9c276cc65a58faf98be8e56962745ec99ab87636 to < fe34430e1f0c5788160508da2265d904c6afab83 · 9c276cc65a58faf98be8e56962745ec99ab87636 to < be48a2b1253655b4f4fdde4c950ff5c87f2ec51a · 9c276cc65a58faf98be8e56962745ec99ab87636 to < 866940b1ccbf8061528986484eac73e44f8a1c52 · 9c276cc65a58faf98be8e56962745ec99ab87636 to < be6be6707c2953dc4ee979e7e4605fe436d87429 · 9c276cc65a58faf98be8e56962745ec99ab87636 to < 5a4d557c02049f75c260dd5492c6e1961e49e77e · 9c276cc65a58faf98be8e56962745ec99ab87636 to < 246c8cc33438a71c28f9b86baa492d9a0a130316 · Other versions: unaffected | Affected | Not stated | Linux |
| Linux | — | Linux5.4 (affected) · 0 to < 5.4 (unaffected · semver) · 5.10.275 through 5.10.* (unaffected · semver) · 5.15.226 through 5.15.* (unaffected · semver) · 6.1.193 through 6.1.* (unaffected · semver) · 6.6.163 through 6.6.* (unaffected · semver) · 6.12.117 through 6.12.* (unaffected · semver) · 6.18.63 through 6.18.* (unaffected · semver) · 7.3.4 through 7.3.* (unaffected · semver) · 7.4-rc1 and later (unaffected · original_commit_for_fix) · Other versions: affected | Version-specific | Not stated | Linux |
| Amazon Linux | AL2 | Release evaluation | Pending Fix; Not Affected | Not stated | Amazon Linux assessment |
| Amazon Linux | AL2023 | Release evaluation | Pending Fix | Not stated | Amazon Linux assessment |
Description
In the Linux kernel, the following vulnerability has been resolved: mm/madvise: atomically clear the young bit on THP MADV_COLD As-is, madvise_cold_or_pageout_pte_range() discards the hardware young bit by invalidating the PMD, doing pmd_mkold() and subsequently writing to the pmd again. However, it does so in a racy manner, looking at a possibly-stale snapshot. It's entirely possible that a write elsewhere set the hardware D bit, which this logic now loses. Fix it by using pmdp_test_and_clear_young(). This is an atomic modification of the PMD entry, and thus safe against any possible racing writes. As a (nice) side-effect, this elides one non-required TLB flush in pmdp_invalidate(). This bug can interact with the swapping system in complicated ways, leading to data loss. For instance, if a folio is marked lazyfree, but was later read from, and then MADV_COLD'd while racing a write to that same THP, dropping the dirty bit may lead to data loss as reclaim/MADV_PAGEOUT drops the "clean" anon folio: T0 T1 ================================================================ MADV_FREE(thp) | folio marked lazyfree | read(thp) | PMD marked young by hardware | | MADV_COLD(thp) write(thp) | if (pmd_young(pmd)) { PMD marked dirty by hardware | set(pmdp, pmd_mkold(pmd)); MADV_PAGEOUT/reclaim | dirty bit may or may not be | set | reclaim/pageout may drop | the folio |
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
No normalized assessments.
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| Linux | Linux | 9c276cc65a58faf98be8e56962745ec99ab87636 to < 9eeed293486a5389bc07232613ed57e875c5bdd8 (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < 17ee2edd085250973eb00cbd98c8b2e0f1a64eda (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < fe34430e1f0c5788160508da2265d904c6afab83 (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < be48a2b1253655b4f4fdde4c950ff5c87f2ec51a (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < 866940b1ccbf8061528986484eac73e44f8a1c52 (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < be6be6707c2953dc4ee979e7e4605fe436d87429 (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < 5a4d557c02049f75c260dd5492c6e1961e49e77e (affected · git)9c276cc65a58faf98be8e56962745ec99ab87636 to < 246c8cc33438a71c28f9b86baa492d9a0a130316 (affected · git)Default: unaffected | Linux · cna |
| Linux | Linux | 5.4 (affected)0 to < 5.4 (unaffected · semver)5.10.275 through 5.10.* (unaffected · semver)5.15.226 through 5.15.* (unaffected · semver)6.1.193 through 6.1.* (unaffected · semver)6.6.163 through 6.6.* (unaffected · semver)6.12.117 through 6.12.* (unaffected · semver)6.18.63 through 6.18.* (unaffected · semver)7.3.4 through 7.3.* (unaffected · semver)7.4-rc1 and later (unaffected · original_commit_for_fix)Default: affected | Linux · cna |
Weaknesses
0No weakness assertions.
References
8- https://git.kernel.org/stable/c/17ee2edd085250973eb00cbd98c8b2e0f1a64eda
- https://git.kernel.org/stable/c/246c8cc33438a71c28f9b86baa492d9a0a130316
- https://git.kernel.org/stable/c/5a4d557c02049f75c260dd5492c6e1961e49e77e
- https://git.kernel.org/stable/c/866940b1ccbf8061528986484eac73e44f8a1c52
- https://git.kernel.org/stable/c/9eeed293486a5389bc07232613ed57e875c5bdd8
- https://git.kernel.org/stable/c/be48a2b1253655b4f4fdde4c950ff5c87f2ec51a
- https://git.kernel.org/stable/c/be6be6707c2953dc4ee979e7e4605fe436d87429
- https://git.kernel.org/stable/c/fe34430e1f0c5788160508da2265d904c6afab83
Provider assertions
1Linux · cna
mm/madvise: atomically clear the young bit on THP MADV_COLD
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- fe189ac83f74541476c629db17d11d253a0776680780918102df0f47f2712200
- Ingested
- 30 Nov 2026, 13:30:07 UTC
- Source record
- Official CVE record