CVE-2025-40218
Description
In the Linux kernel, the following vulnerability has been resolved:
mm/damon/vaddr: do not repeat pte_offset_map_lock() until success
DAMON's virtual address space operation set implementation (vaddr) calls pte_offset_map_lock() inside the page table walk callback function. This is for reading and writing page table accessed bits. If pte_offset_map_lock() fails, it retries by returning the page table walk callback function with ACTION_AGAIN.
pte_offset_map_lock() can continuously fail if the target is a pmd migration entry, though. Hence it could cause an infinite page table walk if the migration cannot be done until the page table walk is finished. This indeed caused a soft lockup when CPU hotplugging and DAMON were running in parallel.
Avoid the infinite loop by simply not retrying the page table walk. DAMON is promising only a best-effort accuracy, so missing access to such pages is no problem.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
A vulnerability in the Linux kernel's DAMON virtual address space operation can cause infinite page table walk and soft lockup when pte_offset_map_lock() fails repeatedly against pmd migration entries.
Vulnerability
Overview
In the Linux kernel, the mm/damon/vaddr implementation calls pte_offset_map_lock() inside the page table walk callback function to read and write page table accessed bits. If pte_offset_map_lock() fails, the code retries by returning ACTION_AGAIN to the page table walker. However, pte_offset_map_lock() can continuously fail when the target is a pmd migration entry, leading to an infinite page table walk loop. This can cause a soft lockup when CPU hotplugging and DAMON are running in parallel [1].
Exploitation
Conditions
No special privileges or network access are required for an attacker to trigger this vulnerability; it occurs during legitimate concurrent operations of CPU hotplugging and DAMON monitoring. The issue is purely a kernel-level denial-of-service condition that arises from the way DAMON handles page table entries during memory management operations. No user interaction is needed beyond having the affected kernel version running with DAMON enabled and CPU hotplug events occurring.
Impact
The vulnerability results in a soft lockup of the system, effectively causing a denial of service (DoS). The system becomes unresponsive, requiring a reboot to recover. This can disrupt critical workloads and potentially lead to data loss if filesystems are not properly synced. The impact is limited to availability; there is no evidence of information disclosure or privilege escalation from this bug.
Mitigation
A patch has been merged into the mainline kernel to address this issue. The fix removes the retry behavior (ACTION_AGAIN) for failed pte_offset_map_lock(), ensuring that the page table walk does not loop infinitely. Because DAMON provides best-effort accuracy, missing access to such pages during migration is acceptable. Users should apply the corresponding stable kernel updates to prevent the soft lockup [1].
AI Insight generated on May 19, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected products
2Patches
4677ebfe5d00fac42320ec8730ccd91cf7495b93af2cc8e03Vulnerability mechanics
Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
4News mentions
0No linked articles in our index yet.