1. Home
  2. Vulnerabilities
  3. CVE-2025-39737

CVE-2025-39737

mm/kmemleak: avoid soft lockup in __kmemleak_do_cleanup()

Published 11 Sept 2025 · modified 5 Nov 2026 · Sources: NVD, CNA (vendor or assigner), EPSS (FIRST)

Low 24/100

Summary

In the Linux kernel, the following vulnerability has been resolved: mm/kmemleak: avoid soft lockup in __kmemleak_do_cleanup() A soft lockup warning was observed on a relative small system x86-64 system with 16 GB of memory when running a debug kernel with kmemleak enabled. watchdog: BUG: soft lockup - CPU#8 stuck for 33s! [kworker/8:1:134] The test system was running a workload with hot unplug happening in parallel. Then kemleak decided to disable itself due to its inability to allocate more kmemleak objects. The debug kernel has its CONFIG_DEBUG_KMEMLEAK_MEM_POOL_SIZE set to 40,000. The soft lockup happened in kmemleak_do_cleanup() when the existing kmemleak objects were being removed and deleted one-by-one in a loop via a workqueue. In this particular case, there are at least 40,000 objects that need to be processed and given the slowness of a debug kernel and the fact that a raw_spinlock has to be acquired and released in __delete_object(), it could take a while to properly handle all these objects. As kmemleak has been disabled in this case, the object removal and deletion process can be further optimized as locking isn't really needed. However, it is probably not worth the effort to optimize for such an edge case that should rarely happen. So the simple solution is to call cond_resched() at periodic interval in the iteration loop to avoid soft lockup.

Affected products and versions

Linux (11 line(s))
Linux
ProductVersionsFixed inSource
Linux 5.4 — CNA (vendor or assigner)
Linux kernel from 5.4.1 (included) to 5.4.297 (excluded) — NVD
Linux kernel from 5.5 (included) to 5.10.241 (excluded) — NVD
Linux kernel from 5.11 (included) to 5.15.190 (excluded) — NVD
Linux kernel from 5.16 (included) to 6.1.149 (excluded) — NVD
Linux kernel from 6.2 (included) to 6.6.103 (excluded) — NVD
Linux kernel from 6.7 (included) to 6.12.43 (excluded) — NVD
Linux kernel from 6.13 (included) to 6.15.11 (excluded) — NVD
Linux kernel from 6.16 (included) to 6.16.2 (excluded) — NVD
Linux kernel 5.4 — NVD
Linux kernel 6.17 — NVD
Debian (1 line(s))
Debian
ProductVersionsFixed inSource
Debian linux 11.0 — NVD

Fix

Not provided by the vendor.

Workaround

No workaround provided.

Check whether you are affected

No verification method provided.

Timeline

  1. — CVE published (cve)

References

Data provenance

Status
NVD
Publication date
NVD
Description
CNA (vendor or assigner)
CVSS score
NVD
Weakness (CWE)
NVD
CVSS vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H (CVSS 3.1, NVD)
Weakness
CWE-401 · Autre (CWE-401)

How this data is obtained and calculated