CVE-2026-23352: x86/efi: defer freeing of boot services memory
In the Linux kernel, the following vulnerability has been resolved:
x86/efi: defer freeing of boot services memory
efifreebootservices() frees memory occupied by EFIBOOTSERVICESCODE and EFIBOOTSERVICESDATA using memblockfreelate().
There are two issue with that: memblockfreelate() should be used for memory allocated with memblockalloc() while the memory reserved with memblockreserve() should be freed with freereservedarea().
More acutely, with CONFIGDEFERREDSTRUCTPAGEINIT=y efifreebootservices() is called before deferred initialization of the memory map is complete.
Benjamin Herrenschmidt reports that this causes a leak of ~140MB of RAM on EC2 t3a.nano instances which only have 512MB or RAM.
If the freed memory resides in the areas that memory map for them is still uninitialized, they won't be actually freed because memblockfreelate() calls memblockfreepages() and the latter skips uninitialized pages.
Using freereservedarea() at this point is also problematic because freepage() accesses the buddy of the freed page and that again might end up in uninitialized part of the memory map.
Delaying the entire efifreebootservices() could be problematic because in addition to freeing boot services memory it updates efi.memmap without any synchronization and that's undesirable late in boot when there is concurrency.
More robust approach is to only defer freeing of the EFI boot services memory.
Split efifreebootservices() in two. First efiunmapbootservices() collects ranges that should be freed into an array then efifreebootservices() later frees them after deferred init is complete.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 6.6.130.1-1 - Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 6.1.176-1Fixed in 6.1.190-1Fixed in 6.12.107-1Fixed in 6.12.113-1Fixed in 7.2.12-1Fixed in 7.2.13-1 - Compensating control
Defer freeing EFI boot services memory until deferred initialization is complete: split efi_free_boot_services() so efi_unmap_boot_services() first collects ranges, then efi_free_boot_services() frees them later without updating efi.memmap during concurrent late boot.
Event History
Frequently Asked Questions
What is the severity of CVE-2026-23352?
CVE-2026-23352 is categorized as a vulnerability that affects memory management in the Linux kernel.
How do I fix CVE-2026-23352?
To mitigate CVE-2026-23352, update to the latest version of the Linux kernel that addresses this specific vulnerability.
What systems are affected by CVE-2026-23352?
CVE-2026-23352 affects systems running specific versions of the Linux kernel, particularly those utilizing EFI boot services.
What are the potential risks of CVE-2026-23352?
CVE-2026-23352 may lead to unintentional memory leaks or instability in the operating system during boot processes.
How can I determine if my system is vulnerable to CVE-2026-23352?
Check the version of the Linux kernel running on your system against the advisories related to CVE-2026-23352 for confirmation.