Description
In the Linux kernel, the following vulnerability has been resolved:
mm: migrate: fix getting incorrect page mapping during page migration
When running stress-ng testing, we found below kernel crash after a few hours:
Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000
pc : dentry_name+0xd8/0x224
lr : pointer+0x22c/0x370
sp : ffff800025f134c0
......
Call trace:
dentry_name+0xd8/0x224
pointer+0x22c/0x370
vsnprintf+0x1ec/0x730
vscnprintf+0x2c/0x60
vprintk_store+0x70/0x234
vprintk_emit+0xe0/0x24c
vprintk_default+0x3c/0x44
vprintk_func+0x84/0x2d0
printk+0x64/0x88
__dump_page+0x52c/0x530
dump_page+0x14/0x20
set_migratetype_isolate+0x110/0x224
start_isolate_page_range+0xc4/0x20c
offline_pages+0x124/0x474
memory_block_offline+0x44/0xf4
memory_subsys_offline+0x3c/0x70
device_offline+0xf0/0x120
......
After analyzing the vmcore, I found this issue is caused by page migration.
The scenario is that, one thread is doing page migration, and we will use the
target page's ->mapping field to save 'anon_vma' pointer between page unmap and
page move, and now the target page is locked and refcount is 1.
Currently, there is another stress-ng thread performing memory hotplug,
attempting to offline the target page that is being migrated. It discovers that
the refcount of this target page is 1, preventing the offline operation, thus
proceeding to dump the page. However, page_mapping() of the target page may
return an incorrect file mapping to crash the system in dump_mapping(), since
the target page->mapping only saves 'anon_vma' pointer without setting
PAGE_MAPPING_ANON flag.
There are seveval ways to fix this issue:
(1) Setting the PAGE_MAPPING_ANON flag for target page's ->mapping when saving
'anon_vma', but this can confuse PageAnon() for PFN walkers, since the target
page has not built mappings yet.
(2) Getting the page lock to call page_mapping() in __dump_page() to avoid crashing
the system, however, there are still some PFN walkers that call page_mapping()
without holding the page lock, such as compaction.
(3) Using target page->private field to save the 'anon_vma' pointer and 2 bits
page state, just as page->mapping records an anonymous page, which can remove
the page_mapping() impact for PFN walkers and also seems a simple way.
So I choose option 3 to fix this issue, and this can also fix other potential
issues for PFN walkers, such as compaction.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| Linux | Linux | 6.1.116 – < 6.1.191, 6.3 | 6.1.191 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | linux | 6.6.15-1 | — |
| Debian 13 | linux | 6.6.15-1 | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 22.04 LTS | linux-azure-6.5 | 6.5.0-1022.23~22.04.1 | USN-6819-1 |
| Ubuntu 22.04 LTS | linux-gcp-6.5 | 6.5.0-1022.24~22.04.1 | USN-6818-1 |
| Ubuntu 22.04 LTS | linux-hwe-6.5 | 6.5.0-41.41~22.04.2 | USN-6818-4 |
| Ubuntu 22.04 LTS | linux-lowlatency-hwe-6.5 | 6.5.0-41.41.1~22.04.1 | USN-6818-1 |
| Ubuntu 22.04 LTS | linux-nvidia-6.5 | 6.5.0-1021.22 | USN-6818-3 |
| Ubuntu 22.04 LTS | linux-oem-6.5 | 6.5.0-1024.25 | USN-6819-3 |
| Ubuntu 22.04 LTS | linux-oracle-6.5 | 6.5.0-1024.24~22.04.1 | USN-6819-4 |
| Ubuntu 22.04 LTS | linux-riscv +23 | No fix yet | — |
| Ubuntu 22.04 LTS | linux-riscv-6.5 | 6.5.0-40.40.1~22.04.1 | — |
| Ubuntu 22.04 LTS | linux-starfive-6.5 | 6.5.0-1015.16~22.04.1 | USN-6819-1 |
| Ubuntu 20.04 LTS | linux-gke +26 | No fix yet | — |
| Ubuntu 18.04 LTS | linux-gcp +13 | No fix yet | — |
| Ubuntu 16.04 LTS | linux-hwe-edge | No fix yet | — |
Show 1 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro Realtime 24.04 LTS | linux-raspi-realtime | 6.8.0-2001.1 | — |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 9 | bpftool | 7.4.0-503.26.1.el9_5 | RHSA-2025:1659 |
| RHEL 9 | rv +65 | 5.14.0-503.26.1.el9_5 | RHSA-2025:1659 |
AlmaLinux
Errata ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| AlmaLinux 9 | bpftool | 7.4.0-503.26.1.el9_5 | ALSA-2025:1659 |
| AlmaLinux 9 | rv +61 | 5.14.0-503.26.1.el9_5 | ALSA-2025:1659 |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 9 | bpftool | 7.4.0-503.11.1.el9_5 | ELSA-2025-1659, ELSA-2024-9315 |
| Oracle Linux 9 | rv +28 | 5.14.0-503.11.1.el9_5 | ELSA-2025-1659, ELSA-2024-9315 |
Advisories 12
- USN-6819-4 linux-oracle-6.5 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-6818-3 linux-nvidia-6.5 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-6818-1 linux, linux-gcp, linux-gcp-6.5, linux-lowlatency, linux-lowlatency-hwe-6.5, linux-raspi vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-6819-3 linux-oem-6.5 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-6818-4 linux-hwe-6.5 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-6819-1 linux-azure, linux-azure-6.5, linux-starfive, linux-starfive-6.5 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- ALSA-2025:1659 Moderate: kernel security update AlmaLinux Security Advisories · Oct 29, 2026
- WID-SEC-2024-0527 Linux Kernel: Mehrere Schwachstellen BSI CERT-Bund (WID) · Aug 4, 2026
- RHSA-2025:1659 Red Hat Security Advisory: kernel security update Red Hat Security Advisories (RHSA) · Jun 26, 2026
- WID-SEC-2025-1293 IBM DataPower Gateway: Mehrere Schwachstellen BSI CERT-Bund (WID) · Dec 3, 2025
- ELSA-2025-1659 Moderate: kernel security update (Oracle Linux 9) Oracle Linux Security Advisories (ELSA) · Feb 28, 2025
- ELSA-2024-9315 Moderate: kernel security update (Oracle Linux 9) Oracle Linux Security Advisories (ELSA) · Nov 14, 2024