mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Waiman Long <llong@redhat.com>
To: Chen Ridong <chenridong@huaweicloud.com>,
	tj@kernel.org, hannes@cmpxchg.org, mkoutny@suse.com
Cc: cgroups@vger.kernel.org, linux-kernel@vger.kernel.org,
	lujialin4@huawei.com, chenridong@huawei.com
Subject: Re: [PATCH -next 3/3] cpuset: remove need_rebuild_sched_domains
Date: Mon, 10 Nov 2025 23:37:16 -0500	[thread overview]
Message-ID: <e5a25c3d-cd81-48bc-bae0-b1b28778272b@redhat.com> (raw)
In-Reply-To: <20251110015228.897736-4-chenridong@huaweicloud.com>


On 11/9/25 8:52 PM, Chen Ridong wrote:
> From: Chen Ridong <chenridong@huawei.com>
>
> Previously, update_cpumasks_hier() used need_rebuild_sched_domains to
> decide whether to invoke rebuild_sched_domains_locked(). Now that
> rebuild_sched_domains_locked() only sets force_rebuild, the flag is
> redundant. Hence, remove it.
>
> Signed-off-by: Chen Ridong <chenridong@huawei.com>
> ---
>   kernel/cgroup/cpuset.c | 6 +-----
>   1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c
> index c357bfb69fe2..22084d8bdc3f 100644
> --- a/kernel/cgroup/cpuset.c
> +++ b/kernel/cgroup/cpuset.c
> @@ -2184,7 +2184,6 @@ static void update_cpumasks_hier(struct cpuset *cs, struct tmpmasks *tmp,
>   {
>   	struct cpuset *cp;
>   	struct cgroup_subsys_state *pos_css;
> -	bool need_rebuild_sched_domains = false;
>   	int old_prs, new_prs;
>   
>   	rcu_read_lock();
> @@ -2348,15 +2347,12 @@ static void update_cpumasks_hier(struct cpuset *cs, struct tmpmasks *tmp,
>   		if (!cpumask_empty(cp->cpus_allowed) &&
>   		    is_sched_load_balance(cp) &&
>   		   (!cpuset_v2() || is_partition_valid(cp)))
> -			need_rebuild_sched_domains = true;
> +			cpuset_force_rebuild();
>   
>   		rcu_read_lock();
>   		css_put(&cp->css);
>   	}
>   	rcu_read_unlock();
> -
> -	if (need_rebuild_sched_domains)
> -		cpuset_force_rebuild();
>   }
>   
>   /**
Reviewed-by: Waiman Long <longman@redhat.com>


  reply	other threads:[~2025-11-11  4:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-10  1:52 [PATCH -next 0/3] cpuset: code cleanups Chen Ridong
2025-11-10  1:52 ` [PATCH -next 1/3] cpuset: simplify node setting on error Chen Ridong
2025-11-10 14:27   ` Michal Koutný
2025-11-11  3:37     ` Chen Ridong
2025-11-11  4:26   ` Waiman Long
2025-11-11  6:16     ` Chen Ridong
2025-11-10  1:52 ` [PATCH -next 2/3] cpuset: remove global remote_children list Chen Ridong
2025-11-11  4:34   ` Waiman Long
2025-11-11  6:17     ` Chen Ridong
2025-11-10  1:52 ` [PATCH -next 3/3] cpuset: remove need_rebuild_sched_domains Chen Ridong
2025-11-11  4:37   ` Waiman Long [this message]
2025-11-11  6:18     ` Chen Ridong

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=e5a25c3d-cd81-48bc-bae0-b1b28778272b@redhat.com \
    --to=llong@redhat.com \
    --cc=cgroups@vger.kernel.org \
    --cc=chenridong@huawei.com \
    --cc=chenridong@huaweicloud.com \
    --cc=hannes@cmpxchg.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lujialin4@huawei.com \
    --cc=mkoutny@suse.com \
    --cc=tj@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

all inboxes | Powered by JetHome®