CVE-2026-99666
mm/khugepaged: fix PMD table lock leak in try_collapse_pte_mapped_thp()
- CVSS
- —
- EPSS
- 0.17% (p6)
- Published
- 2026-11-20
- Age
- 14d old
- Modified
- 2026-11-20
- Product
- Linux Linux
Description
In the Linux kernel, the following vulnerability has been resolved: mm/khugepaged: fix PMD table lock leak in try_collapse_pte_mapped_thp() For a private mapping with userfaultfd, try_collapse_pte_mapped_thp() takes the PMD table lock before it maps the page table for the second time. If that (pte_offset_map_rw_nolock) fails, because the page table vanished in the meantime due to concurrent page table reclaim, it leaves through the abort label, where the PMD table lock is unlocked if it differs from PTE table lock. In case the PMD table lock and the PTE table lock match, which is the case without CONFIG_SPLIT_PTE_PTLOCKS after pte_offset_map_rw_nolock() failed, we miss to unlock the PMD table. To fix it, forget the PTE table lock when we unmap+unlock the PTE table. Fix generated by an LLM and sent by Josef Bacik in private. [ david: move the ptl = NULL handling; rewrite description, drop wrong comments ]
Fixed in
6.18.64 · 7.3.5 · 7c1170ce1b74a8cd83da2174a3eb9e0755bb1b16 · ad5e5800ce560759c8d3c10aac15b48a06cd21c1 · db38b902307e687219ec765ef51a6ef459746c87
Affected packages
| Ecosystem | Package | Range | Fixed |
|---|---|---|---|
| Linux | Kernel | >=6.14.0, <6.18.64 | 6.18.64 |
| Linux | Kernel | >=6.19.0, <7.3.5 | 7.3.5 |
| vendor | Linux | >=6375e95f381e3dc85065b6f74263a61522736203, <7c1170ce1b74a8cd83da2174a3eb9e0755bb1b16 | 7c1170ce1b74a8cd83da2174a3eb9e0755bb1b16 |
| vendor | Linux | >=6375e95f381e3dc85065b6f74263a61522736203, <ad5e5800ce560759c8d3c10aac15b48a06cd21c1 | ad5e5800ce560759c8d3c10aac15b48a06cd21c1 |
| vendor | Linux | >=6375e95f381e3dc85065b6f74263a61522736203, <db38b902307e687219ec765ef51a6ef459746c87 | db38b902307e687219ec765ef51a6ef459746c87 |
Sources
- NVD · first seen 14d ago · NVD terms of use
- OSV · first seen 13d ago · CC-BY 4.0
- CVE List · first seen 14d ago · CVE Terms of Use
References
- https://git.kernel.org/stable/c/7c1170ce1b74a8cd83da2174a3eb9e0755bb1b16 other
- https://git.kernel.org/stable/c/ad5e5800ce560759c8d3c10aac15b48a06cd21c1 other
- https://git.kernel.org/stable/c/db38b902307e687219ec765ef51a6ef459746c87 other
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99666.json advisory
- https://nvd.nist.gov/vuln/detail/CVE-2026-99666 advisory
- https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git package