Re: [PATCH v2] tools/workqueue/wq_dump.py: Add busy worker inspection and BH pool states
From: Tejun Heo
Date: Sun Sep 13 2026 - 12:04:04 EST
Hello, Aaron.
On Fri, Sep 11, 2026 at 05:06:25PM -0400, Aaron Tomlin wrote:
> + for bkt in pool.busy_hash:
> + for worker in hlist_for_each_entry('struct worker', bkt.address_of_(), 'hentry'):
worker->hentry shares storage with the idle-list entry, so a worker going
idle can send this iterator into the circular idle list. Leaving idle can
leave a self-link with WORKER_IDLE clear. The per-worker retries do not
bound either case.
Could you break out of the bucket on an idle worker, a repeated address, or
a traversal read fault? Warn that the pool's busy-worker output is
incomplete and ask the user to retry, then continue with the other pools.
The exception handler needs to cover iterator advancement too.
Thanks.
--
tejun