linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Lai Jiangshan <jiangshanlai@gmail.com>
Cc: linux-kernel@vger.kernel.org,
	Lai Jiangshan <jiangshan.ljs@antgroup.com>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Tejun Heo <tj@kernel.org>, Petr Mladek <pmladek@suse.com>,
	Michal Hocko <mhocko@suse.com>,
	Wedson Almeida Filho <wedsonaf@google.com>,
	Valentin Schneider <vschneid@redhat.com>
Subject: Re: [RFC PATCH 1/8] workqueue: Unconditionally set cpumask in worker_attach_to_pool()
Date: Mon, 12 Sep 2022 09:54:34 +0200	[thread overview]
Message-ID: <Yx7luoAJpenWO5zK@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <20220804084135.92425-2-jiangshanlai@gmail.com>

On Thu, Aug 04, 2022 at 04:41:28PM +0800, Lai Jiangshan wrote:
> From: Lai Jiangshan <jiangshan.ljs@antgroup.com>
> 
> If a worker is spuriously woken up after kthread_bind_mask() but before
> worker_attach_to_pool(), and there are some cpu-hot-[un]plug happening
> during the same interval, the worker task might be pushed away from its
> bound CPU with its affinity changed by the scheduler and worker_attach_to_pool()
> doesn't rebind it properly.

Can you *please* be more explicit. The above doesn't give me enough clue
to reconstruct the actual scenario you're fixing.

Draw a picture or something.

  parent reply	other threads:[~2022-09-12  7:55 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-04  8:41 [RFC PATCH 0/8] workqueue: Fix for prematurely wakeups and cleanups Lai Jiangshan
2022-08-04  8:41 ` [RFC PATCH 1/8] workqueue: Unconditionally set cpumask in worker_attach_to_pool() Lai Jiangshan
2022-08-16 21:18   ` Tejun Heo
2022-08-18 14:39     ` Lai Jiangshan
2022-09-12  7:54   ` Peter Zijlstra [this message]
2022-08-04  8:41 ` [RFC PATCH 2/8] workqueue: Make create_worker() safe against prematurely wakeups Lai Jiangshan
     [not found]   ` <20220804123520.1660-1-hdanton@sina.com>
2022-08-05  2:30     ` Lai Jiangshan
2022-08-16 21:46   ` Tejun Heo
2022-08-04  8:41 ` [RFC PATCH 3/8] workqueue: Set PF_NO_SETAFFINITY instead of kthread_bind_mask() Lai Jiangshan
2022-08-04  8:41 ` [RFC PATCH 4/8] workqueue: Set/Clear PF_WQ_WORKER while attaching/detaching Lai Jiangshan
2022-08-04  8:41 ` [RFC PATCH 5/8] workqueue: Use worker_set_flags() in worker_enter_idle() Lai Jiangshan
2022-08-04  8:41 ` [RFC PATCH 6/8] workqueue: Simplify the starting of the newly created worker Lai Jiangshan
2022-08-04  8:41 ` [RFC PATCH 7/8] workqueue: Remove the outer loop in maybe_create_worker() Lai Jiangshan
2022-08-16 22:08   ` Tejun Heo
2022-08-18 14:44     ` Lai Jiangshan
2022-08-19 17:29       ` Tejun Heo
2022-08-04  8:41 ` [RFC PATCH 8/8] workqueue: Move the locking out of maybe_create_worker() 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=Yx7luoAJpenWO5zK@hirez.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=ebiederm@xmission.com \
    --cc=jiangshan.ljs@antgroup.com \
    --cc=jiangshanlai@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhocko@suse.com \
    --cc=pmladek@suse.com \
    --cc=tj@kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=vschneid@redhat.com \
    --cc=wedsonaf@google.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;
as well as URLs for NNTP newsgroup(s).