# CVE-2026-89759: mm/kmemleak: avoid soft lockup when scanning task stacks

- Severity: not scored yet
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.22%, higher than 12% of CVEs (2026-12-01)
- Published: 2026-09-11T19:47:01.313Z
- Modified: 2026-10-30T13:20:28.370Z
- Assigned by: Linux

## Description

In the Linux kernel, the following vulnerability has been resolved:

mm/kmemleak: avoid soft lockup when scanning task stacks

Patch series "mm/kmemleak: avoid soft lockup when scanning task", v3.

kmemleak_scan() scans every task stack under one rcu_read_lock() with no
reschedule point, which can trip the soft lockup watchdog on hosts with
very many threads.

That prints the following message, depending on the workload+host
configuration:

      watchdog: BUG: soft lockup - CPU#35 stuck for 22s! [kmemleak:537]
       scan_block
       kmemleak_scan
       kmemleak_scan_thread
       kthread

Patch 1 walks the tasks with find_ge_pid() so the scan reschedules between
tasks

Patches 2-3 let the scan loops stop early once a scan is interrupted.


This patch (of 3):

kmemleak_scan() walks every thread and scans its kernel stack under a
single rcu_read_lock() with no reschedule point.  On a host with very many
threads -- amplified by KASAN/lockdep in debug builds -- this loop can hog
a CPU long enough to trip the soft lockup watchdog:

  watchdog: BUG: soft lockup - CPU#35 stuck for 22s! [kmemleak:537]
   scan_block
   kmemleak_scan
   kmemleak_scan_thread
   kthread

A cond_resched() cannot be added directly: the loop runs inside an RCU
read-side critical section.

Walk the tasks one PID at a time with find_ge_pid(), taking the RCU read
lock only to look up and pin each task.  The stack is then scanned with no
lock held, so cond_resched() runs between tasks and the scan stops early
on scan_should_stop().  This follows the next_tgid()/task_seq_get_next()
iteration pattern and keeps each RCU critical section short.

(As written by CVE List.)

## Affected

- Linux Linux: from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before 2567818c2776d0a820506c3612261d9e24af7164; from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before f1cd6c4c35243377882c47236281d03ee3be6eeb; from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before 9a1b12c06c192290b8479de48f66f1e75d89c4b7; from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before 3fc8044251de21555fb02c365fa681bab8b0db55; from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before 1838c704bcb4fd3556cf67513c6f97a39099e35c; from c4b28963fd79457315783b3b0f21c01eb88cfdc1 before 5d10d4e19e6daa487f0cd0ea6cba472325de92f9; 5.10 (not affected: before 5.10; from 6.1.191 up to 6.1.*; from 6.6.160 up to 6.6.*; from 6.12.109 up to 6.12.*; from 6.18.50 up to 6.18.*; from 7.2.4 up to 7.2.*; from 7.3 up to *)

## References

- <https://git.kernel.org/stable/c/2567818c2776d0a820506c3612261d9e24af7164>
- <https://git.kernel.org/stable/c/f1cd6c4c35243377882c47236281d03ee3be6eeb>
- <https://git.kernel.org/stable/c/9a1b12c06c192290b8479de48f66f1e75d89c4b7>
- <https://git.kernel.org/stable/c/3fc8044251de21555fb02c365fa681bab8b0db55>
- <https://git.kernel.org/stable/c/1838c704bcb4fd3556cf67513c6f97a39099e35c>
- <https://git.kernel.org/stable/c/5d10d4e19e6daa487f0cd0ea6cba472325de92f9>

## Sources

- CVE List: [CVE-2026-89759](https://www.cve.org/CVERecord?id=CVE-2026-89759), CVE Terms of Use, modified 2026-10-30
- NVD: [CVE-2026-89759](https://nvd.nist.gov/vuln/detail/CVE-2026-89759), Public domain, modified 2026-10-30

---

Page: https://cve.day/CVE-2026-89759 · Whole record: https://cve.day/CVE-2026-89759.json · Rebuilt by cve.day 2026-11-25T22:59:38.139Z
