From: Mel Gorman <mgorman@suse.de>
To: Abel Wu <wuyun.abel@bytedance.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
Vincent Guittot <vincent.guittot@linaro.org>,
Rohit Jain <rohit.k.jain@oracle.com>,
Ingo Molnar <mingo@kernel.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] sched/fair: Fix misuse of available_idle_cpu()
Date: Thu, 8 Sep 2022 11:36:32 +0100 [thread overview]
Message-ID: <20220908103632.yzm5boxrr3nmvhpm@suse.de> (raw)
In-Reply-To: <20220908080702.58938-1-wuyun.abel@bytedance.com>
On Thu, Sep 08, 2022 at 04:07:02PM +0800, Abel Wu wrote:
> The function available_idle_cpu() was introduced to distinguish
> between the code paths that cares if the vCPU is preempted and
> the ones don't care. In general, available_idle_cpu() is used in
> selecting cpus for immediate use, e.g. ttwu. While idle_cpu() is
> used in the paths that only cares about the cpu is idle or not,
> and __update_idle_core() is one of them.
>
> Use idle_cpu() instead in the idle path to make has_idle_core
> a better hint.
>
> Fixes: 943d355d7fee (sched/core: Distinguish between idle_cpu() calls based on desired effect, introduce available_idle_cpu())
> Signed-off-by: Abel Wu <wuyun.abel@bytedance.com>
Seems fair. As vCPU preemption is specific to virtualisation, it is very
unlikely that SMT is exposed to the guest so the impact of the patch is
minimal but I still think it's right so;
Acked-by: Mel Gorman <mgorman@suse.de>
--
Mel Gorman
SUSE Labs
next prev parent reply other threads:[~2022-09-08 10:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-08 8:07 Abel Wu
2022-09-08 10:36 ` Mel Gorman [this message]
2022-09-08 13:17 ` Peter Zijlstra
2022-09-08 13:49 ` Abel Wu
2022-09-20 7:42 ` Abel Wu
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=20220908103632.yzm5boxrr3nmvhpm@suse.de \
--to=mgorman@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=rohit.k.jain@oracle.com \
--cc=vincent.guittot@linaro.org \
--cc=wuyun.abel@bytedance.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®