[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <67d46976.050a0220.13a4aa.9cf4@mx.google.com>
Date: Fri, 14 Mar 2025 10:37:54 -0700
From: Boqun Feng <boqun.feng@...il.com>
To: Lance Yang <ioworker0@...il.com>
Cc: akpm@...ux-foundation.org, will@...nel.org, peterz@...radead.org,
mingo@...hat.com, longman@...hat.com, mhiramat@...nel.org,
anna.schumaker@...cle.com, joel.granados@...nel.org,
kent.overstreet@...ux.dev, leonylgao@...cent.com,
linux-kernel@...r.kernel.org, rostedt@...dmis.org,
senozhatsky@...omium.org, tfiga@...omium.org, amaindex@...look.com,
John Stultz <jstultz@...gle.com>
Subject: Re: [PATCH RESEND v2 0/3] hung_task: extend blocking task stacktrace
dump to semaphore
Hi Lance,
On Fri, Mar 14, 2025 at 10:42:57PM +0800, Lance Yang wrote:
> Hi all,
>
> Inspired by mutex blocker tracking[1], this patch series extend the
> feature to not only dump the blocker task holding a mutex but also to
> support semaphores. Unlike mutexes, semaphores lack explicit ownership
> tracking, making it challenging to identify the root cause of hangs. To
> address this, we introduce a last_holder field to the semaphore structure,
> which is updated when a task successfully calls down() and cleared during
> up().
>
> The assumption is that if a task is blocked on a semaphore, the holders
> must not have released it. While this does not guarantee that the last
> holder is one of the current blockers, it likely provides a practical hint
> for diagnosing semaphore-related stalls.
>
Could you copy John Stultz for the future versions? Because John is
working on proxy execution, which will make a task always track which
mutex it's blocked by:
https://lore.kernel.org/lkml/20250312221147.1865364-3-jstultz@google.com/
I feel it's better to build the hung task detection with that in mind,
thanks!
Regards,
Boqun
[...]
Powered by blists - more mailing lists