From: Tejun Heo <tj@kernel.org>
To: Petr Mladek <pmladek@suse.com>
Cc: Song Liu <song@kernel.org>,
linux-kernel@vger.kernel.org, jiangshanlai@gmail.com,
leitao@debian.org, kernel-team@meta.com, puranjay@kernel.org
Subject: Re: [PATCH v2] workqueue: Fix false positive stall reports
Date: Tue, 24 Mar 2026 04:15:46 -1000 [thread overview]
Message-ID: <acKckqH2zFF9DByF@slm.duckdns.org> (raw)
In-Reply-To: <acJg-jPT83KsH-90@pathway.suse.cz>
On Tue, Mar 24, 2026 at 11:01:30AM +0100, Petr Mladek wrote:
> You know, the code makes my head spin because it violates the usual
> locking rules. The lock should serialize 2 or more writes/reads.
> It works only when all the reads/writes are done under the lock.
> But it is not the case here.
It's unusual but not unique. We would have used spin_unlock_wait() here (w/
rmb()) here but we don't have that anymore. Maybe a clearer way to indicate
what's going on now is just doing lock/unlock() cycle without doing anything
inside, but, as long as the comment explains what's going on, I think either
way is fine. So, if anyone can improve the comment without writing a novel,
plesae go ahead.
Thanks.
--
tejun
next prev parent reply other threads:[~2026-03-24 14:15 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-22 3:30 Song Liu
2026-03-22 4:41 ` Tejun Heo
2026-03-23 14:09 ` Petr Mladek
2026-03-23 18:31 ` Song Liu
2026-03-24 10:01 ` Petr Mladek
2026-03-24 14:15 ` Tejun Heo [this message]
2026-03-24 18:22 ` Song Liu
2026-03-25 13:19 ` Petr Mladek
2026-03-25 14:12 ` Petr Mladek
2026-03-25 15:36 ` Song Liu
2026-03-25 15:53 ` [PATCH v2] workqueue: Better describe stall check Tejun Heo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=acKckqH2zFF9DByF@slm.duckdns.org \
--to=tj@kernel.org \
--cc=jiangshanlai@gmail.com \
--cc=kernel-team@meta.com \
--cc=leitao@debian.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pmladek@suse.com \
--cc=puranjay@kernel.org \
--cc=song@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome