CVE-2026-99656

mm/madvise: fix data loss from MADV_FREE on a KSM page

State
Published
Severity
Not scored
Published
Nov 20, 2026
Updated
Nov 20, 2026
Reserved
Sep 25, 2026

Read the record on cve.org

Description

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

mm/madvise: fix data loss from MADV_FREE on a KSM page

MADV_FREE can clear the dirty flag of a singly mapped KSM folio. The folio remains in the stable tree and can gain new mappings without being dirtied again. Once marked lazyfree, reclaim can discard data that those mappings still need.

KSM always marks a folio dirty when converting it to a KSM folio in try_to_merge_one_page(). Marking a folio lazyfree clears PG_swapbacked but leaves PG_dirty unchanged. Preserving PG_dirty makes reclaim restore PG_swapbacked instead of discarding the folio. This also protects folios that were already lazyfree when KSM converted them.

Skip KSM folios before clearing their dirty flag, checking under the folio lock to serialize with KSM conversion.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • 854e9ed09dedf0c19ac8640e91bcc74bc3f9e5c9 to before af2feafb0437fab5ed9d02eeb1c06ef66e05c55aAffected
  • 854e9ed09dedf0c19ac8640e91bcc74bc3f9e5c9 to before 8b6860f17b4de23a0b19045c066dc0679e50f0baAffected
  • 854e9ed09dedf0c19ac8640e91bcc74bc3f9e5c9 to before 64f273b71bf714dd22b803a87d65bb40faaffcadAffected
  • 854e9ed09dedf0c19ac8640e91bcc74bc3f9e5c9 to before 22d043c1da48d6c7274f9dd900714b6d58b7b9c6Affected
LinuxLinux
  • 4.5Affected
  • before 4.5Not affected
  • 6.12.118 through 6.12.*Not affected
  • 6.18.64 through 6.18.*Not affected
  • 7.3.5 through 7.3.*Not affected
  • 7.4-rc2 and laterNot affected

References

Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.

© 2026 NVIDIA, the NVIDIA logo, and NVIDIA Inception are trademarks and/or registered trademarks of NVIDIA Corporation in the U.S. and other countries.