From: Tejun Heo <tj@kernel.org>
To: Lai Jiangshan <jiangshanlai@gmail.com>
Cc: linux-kernel@vger.kernel.org, ying chen <yc1082463@gmail.com>,
Lai Jiangshan <jiangshan.ljs@antgroup.com>
Subject: Re: [PATCH V4 1/4] workqueue: Loop over in rescuer until all its work is done
Date: Tue, 2 Dec 2025 08:07:25 -1000 [thread overview]
Message-ID: <aS8q3fcnU91uPu0J@slm.duckdns.org> (raw)
In-Reply-To: <20251125063617.671199-2-jiangshanlai@gmail.com>
On Tue, Nov 25, 2025 at 02:36:14PM +0800, Lai Jiangshan wrote:
> From: Lai Jiangshan <jiangshan.ljs@antgroup.com>
>
> Simplify the rescuer work by looping directly in the rescuer rather than
> adding the pwq back to the maydays list. This also helps when
> max_requests is 1 or small but pwq->inactive_works has a large number of
> pending work items.
>
> This might hurt fairness among PWQs and the rescuer could end up being
> stuck on one PWQ indefinitely, but the rescuer's objective is to make
> forward progress rather than ensure fairness.
>
> Fairness can be further improved in future by assigning work items to
> the rescuer one by one and this is a temporary change to ease the
> transition.
Again, I'd just note that this is temporary removal rather than trying
justify that fairness doesn't matter because I think it does (not in terms
of theoretical correctness but in the practical approach of avoiding
unnecessary surprises) and the behavior is restored by a later patch.
Thanks.
--
tejun
next prev parent reply other threads:[~2025-12-02 18:07 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-25 6:36 [PATCH V4 0/4] workqueue: Factor the way to assign rescuer work Lai Jiangshan
2025-11-25 6:36 ` [PATCH V4 1/4] workqueue: Loop over in rescuer until all its work is done Lai Jiangshan
2025-12-02 18:07 ` Tejun Heo [this message]
2025-11-25 6:36 ` [PATCH V4 2/4] workqueue: Process rescuer work items one-by-one using a cursor Lai Jiangshan
2025-11-25 6:36 ` [PATCH V4 3/4] workqueue: Limit number of processed works in rescuer per turn Lai Jiangshan
2025-12-02 18:16 ` Tejun Heo
2025-12-03 3:22 ` Lai Jiangshan
2025-12-03 19:41 ` Tejun Heo
2025-11-25 6:36 ` [PATCH V4 4/4] workqueue: Process extra works in rescuer when there are no more to rescue Lai Jiangshan
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=aS8q3fcnU91uPu0J@slm.duckdns.org \
--to=tj@kernel.org \
--cc=jiangshan.ljs@antgroup.com \
--cc=jiangshanlai@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=yc1082463@gmail.com \
/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
all inboxes | Powered by JetHome®