[PATCH 0/2] sched_ext: Improve watchdog stall diagnostics

From: Changwoo Min

Date: Tue Apr 07 2026 - 23:11:51 EST


When a watchdog timeout fires on a system with many CPUs, the per-CPU
state dump in the exit info can get truncated. If the stall CPU happens
to be in the middle or end of the CPU list, its state may never appear
in the output, making it difficult to diagnose the hang.

This series addresses that by always dumping the stall CPU first.

Patch 1 is a preparatory refactor that extracts the per-CPU dump logic
into a scx_dump_cpu() helper, making patch 2 straightforward.

Patch 2 adds a stall_cpu field to scx_exit_info, threads it through
the exit path, and reorders the dump loop to emit the stall CPU before
all others.

Changwoo Min (2):
sched_ext: Extract scx_dump_cpu() from scx_dump_state()
sched_ext: Dump the stall CPU first in watchdog exit

kernel/sched/ext.c | 202 +++++++++++++++++++-----------------
kernel/sched/ext_internal.h | 3 +
2 files changed, 112 insertions(+), 93 deletions(-)

--
2.53.0