CVE-2026-64302 PUBLISHED

x86/mm: Fix freeing of PMD-sized vmemmap pages

Assigner: Linux
Reserved: 19.07.2026 Published: 25.07.2026 Updated: 25.07.2026

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

x86/mm: Fix freeing of PMD-sized vmemmap pages

Commit bf9e4e30f353 ("x86/mm: use pagetable_free()"), switched from freeing non-boot page tables through __free_pages() to pagetable_free().

However, the function is also called to free vmemmap pages.

Given that vmemmap pages are not page tables, already the page_ptdesc(page) is wrong. But worse, pagetable_free() calls:

<pre>__free_pages(page, compound_order(page)); </pre>

Since vmemmap pages are not compound pages (see vmemmap_alloc_block()) -- except for HVO, which doesn't apply here -- only first page of a PMD-sized vmemmap page is freed, leaking the other ones.

Fix it by properly decoupling pagetable and vmemmap freeing. free_pagetable() no longer has to mess with SECTION_INFO, as only the vmemmap is marked like that in register_page_bootmem_memmap().

The indentation in remove_pmd_table() is messed up. Fix that while touching it.

Bootmem info handling will soon be fixed up. For now, handle it similar to free_pagetable(), just avoiding the ifdef.

[ dhansen: changelog munging. More imperative voice ]

Product Status

Vendor Linux
Product Linux
Versions Default: unaffected
  • affected from a1593c90896babf33e947910c7aecb9f50bab993 to add1e4112e00b619614784bf630aeebfdefa23e1 (excl.)
  • affected from bf9e4e30f3538391745a99bc2268ec4f5e4a401e to 03f6ecbc446c33b38fd452cd3c494092a8116967 (excl.)
  • affected from bf9e4e30f3538391745a99bc2268ec4f5e4a401e to 39406c05f8f150f1685839acd38ffdd69ff92031 (excl.)
  • affected from 6.18.7 to 6.18.39 (excl.)
Vendor Linux
Product Linux
Versions Default: affected
  • Version 6.19 is affected
  • unaffected from 0 to 6.19 (excl.)
  • unaffected from 6.18.39 to 6.18.* (incl.)
  • unaffected from 7.1.4 to 7.1.* (incl.)
  • unaffected from 7.2-rc1 to * (incl.)

References