{"id":"CVE-2026-99649","summary":"mm/ksm: check large swap-cache folios before mapping them","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nmm/ksm: check large swap-cache folios before mapping them\n\nKSM folios are always small, but their shared swap slots can be read\nback as part of a large folio in the swap cache. ksm_might_need_to_copy()\nskips large folios, so another process can map a page with an incompatible\nanon_vma or page index. Reverse mapping then cannot find the new\nmapping, preventing migration or reclaim.\n\nApply the same compatibility checks to large folios as to small ones.\nPass the page corresponding to the swap entry and copy only that page\nwhen necessary. In do_swap_page()'s copy path, decrement only that slot's\nswap count, because the source swap-cache folio can now be large.\n\nFix generated by an LLM and sent by Chris Mason in private.","modified":"2026-11-20T07:00:56.711570017Z","published":"2026-11-20T05:50:03.077Z","database_specific":{"cna_assigner":"Linux","osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99649.json"},"references":[{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"},{"type":"WEB","url":"https://git.kernel.org/stable/c/7f2c000ffb1047b476cbf267f741272c389d3e31"},{"type":"WEB","url":"https://git.kernel.org/stable/c/cc4b71683ee9d8d4ed0b25c0744314005fb3e395"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99649.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-99649"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"f1879e8a0c601de78a356016e216241b43de9208"},{"fixed":"cc4b71683ee9d8d4ed0b25c0744314005fb3e395"},{"fixed":"7f2c000ffb1047b476cbf267f741272c389d3e31"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-99649.json"}},{"package":{"name":"Kernel","ecosystem":"Linux"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"7.0.0"},{"fixed":"7.3.5"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-99649.json"}}],"schema_version":"1.9.2"}