From nobody Mon Feb 9 05:06:01 2026 Received: from dggsgout11.his.huawei.com (dggsgout11.his.huawei.com [45.249.212.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E4BEA3F9FB; Mon, 10 Nov 2025 02:07:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; cv=none; b=q+GO6+eWsfygfNeUjxXTQc8kihIiRyjRPgS7gzwwW7uMmDd12kxkyAX69YZsoP0AQvkWuFR3HrutlllS0KT8CS0wz9yXnAVH+KAKnKp14mwaGKV98NOen4PxsiAXIFp6XchrqcmPkto3Fv1gg09JvXhOiPT7VIAgHls7LFoaQns= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; c=relaxed/simple; bh=o7BdpqTSZH61cu5ofyfQozUm+TBZC7KAhmdZa4XkkxE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Flvij4yLb61HG9oxFZVlqgo2wx8Svvq5tHcfAlWXfPzX63ogeZHVHgs3wKFYmRfLIqNm6TePKeXQtmFLrPQ+bEkeD6iHPeurhfaj107VGzcvJdc/EeSaA18kTnRXzCES43JbM8WenbVy5M1jzA8RXTzu7YnjxrUuu8IqasNhKEo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com; spf=pass smtp.mailfrom=huaweicloud.com; arc=none smtp.client-ip=45.249.212.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huaweicloud.com Received: from mail.maildlp.com (unknown [172.19.93.142]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTPS id 4d4Y2N0wf9zYQtwp; Mon, 10 Nov 2025 10:07:08 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id 725D71A0902; Mon, 10 Nov 2025 10:07:32 +0800 (CST) Received: from hulk-vt.huawei.com (unknown [10.67.174.121]) by APP1 (Coremail) with SMTP id cCh0CgBXkUrUSBFpPBDaAA--.6382S3; Mon, 10 Nov 2025 10:07:32 +0800 (CST) From: Chen Ridong To: longman@redhat.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: [PATCH -next 1/3] cpuset: simplify node setting on error Date: Mon, 10 Nov 2025 01:52:26 +0000 Message-Id: <20251110015228.897736-2-chenridong@huaweicloud.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20251110015228.897736-1-chenridong@huaweicloud.com> References: <20251110015228.897736-1-chenridong@huaweicloud.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: cCh0CgBXkUrUSBFpPBDaAA--.6382S3 X-Coremail-Antispam: 1UD129KBjvJXoW7tw1kur4xXrykCw4xGF13XFb_yoW8Xw4xpF W7G3WUArW5Jry3G395t39xWFyqg348JF9rGFnFqa4fCasFyF9FkF1DXwnrAFW7JF9xCF15 JFsayFW8uF9rt37anT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUU9Kb4IE77IF4wAFF20E14v26ryj6rWUM7CY07I20VC2zVCF04k2 6cxKx2IYs7xG6rWj6s0DM7CIcVAFz4kK6r1j6r18M28IrcIa0xkI8VA2jI8067AKxVWUGw A2048vs2IY020Ec7CjxVAFwI0_JFI_Gr1l8cAvFVAK0II2c7xJM28CjxkF64kEwVA0rcxS w2x7M28EF7xvwVC0I7IYx2IY67AKxVWDJVCq3wA2z4x0Y4vE2Ix0cI8IcVCY1x0267AKxV W8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK6I8E87Iv6xkF7I0E14v2 6rxl6s0DM2AIxVAIcxkEcVAq07x20xvEncxIr21l5I8CrVACY4xI64kE6c02F40Ex7xfMc Ij6xIIjxv20xvE14v26r106r15McIj6I8E87Iv67AKxVWUJVW8JwAm72CE4IkC6x0Yz7v_ Jr0_Gr1lF7xvr2IYc2Ij64vIr41lc7CjxVAaw2AFwI0_JF0_Jw1l42xK82IYc2Ij64vIr4 1l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK 67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r1q6r43MIIYrxkI7VAKI48JMIIF0xvE2Ix0cI 8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAv wI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14 v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjxUw9a9UUUUU X-CM-SenderInfo: hfkh02xlgr0w46kxt4xhlfz01xgou0bp/ Content-Type: text/plain; charset="utf-8" From: Chen Ridong There is no need to jump to the 'done' label upon failure, as no cleanup is required. Return the error code directly instead. Signed-off-by: Chen Ridong Reviewed-by: Michal Koutn=C3=BD Reviewed-by: Waiman Long --- kernel/cgroup/cpuset.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c index 8238fd8c0c29..c90476d52f09 100644 --- a/kernel/cgroup/cpuset.c +++ b/kernel/cgroup/cpuset.c @@ -2897,21 +2897,19 @@ static int update_nodemask(struct cpuset *cs, struc= t cpuset *trialcs, */ retval =3D nodelist_parse(buf, trialcs->mems_allowed); if (retval < 0) - goto done; + return retval; =20 if (!nodes_subset(trialcs->mems_allowed, - top_cpuset.mems_allowed)) { - retval =3D -EINVAL; - goto done; - } + top_cpuset.mems_allowed)) + return -EINVAL; + + /* No change? nothing to do */ + if (nodes_equal(cs->mems_allowed, trialcs->mems_allowed)) + return 0; =20 - if (nodes_equal(cs->mems_allowed, trialcs->mems_allowed)) { - retval =3D 0; /* Too easy - nothing to do */ - goto done; - } retval =3D validate_change(cs, trialcs); if (retval < 0) - goto done; + return retval; =20 check_insane_mems_config(&trialcs->mems_allowed); =20 @@ -2921,8 +2919,7 @@ static int update_nodemask(struct cpuset *cs, struct = cpuset *trialcs, =20 /* use trialcs->mems_allowed as a temp variable */ update_nodemasks_hier(cs, &trialcs->mems_allowed); -done: - return retval; + return 0; } =20 bool current_cpuset_is_being_rebound(void) --=20 2.34.1 From nobody Mon Feb 9 05:06:01 2026 Received: from dggsgout12.his.huawei.com (dggsgout12.his.huawei.com [45.249.212.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DCB8C34D395; Mon, 10 Nov 2025 02:07:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.56 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; cv=none; b=T5lDzCUDaStOCt95Ss3l9u5qIveE+5E4kebD645xvQ1MrP1KQ6digceoH3V+jtKfH7DU1CVOZNLG+TzwK+38SScfjoUczcS8n7nS1riDoNUl8NuMn2EnFKFw1ROTgAS4ZPTXZ4bkM2/SK12kg11MXZijQ6wS6NNWMOIuq7VHuRY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; c=relaxed/simple; bh=gGd3la4AyOU2leXqeS6koFFQL/parkUNhYrfsYMD7/c=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Q96L08Lt/26mQyTdxFqmaNO75fFfZ7NqlQCS4Uj/RzOx/6Y9Jgvr3Xwfi7Wl4YZCliOHZsSXdtnz/UEXAbofYQsvFBfdGBU8IGFGcKbMZWgy+dHUecYYR7Hha9XN4UlIGFlNBLBjl02+42py53+uoi1wt51AxszPPMppBse5POU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com; spf=pass smtp.mailfrom=huaweicloud.com; arc=none smtp.client-ip=45.249.212.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huaweicloud.com Received: from mail.maildlp.com (unknown [172.19.163.216]) by dggsgout12.his.huawei.com (SkyGuard) with ESMTPS id 4d4Y2Z3pXrzKHMSf; Mon, 10 Nov 2025 10:07:18 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id 7EF841A19BF; Mon, 10 Nov 2025 10:07:32 +0800 (CST) Received: from hulk-vt.huawei.com (unknown [10.67.174.121]) by APP1 (Coremail) with SMTP id cCh0CgBXkUrUSBFpPBDaAA--.6382S4; Mon, 10 Nov 2025 10:07:32 +0800 (CST) From: Chen Ridong To: longman@redhat.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: [PATCH -next 2/3] cpuset: remove global remote_children list Date: Mon, 10 Nov 2025 01:52:27 +0000 Message-Id: <20251110015228.897736-3-chenridong@huaweicloud.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20251110015228.897736-1-chenridong@huaweicloud.com> References: <20251110015228.897736-1-chenridong@huaweicloud.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: cCh0CgBXkUrUSBFpPBDaAA--.6382S4 X-Coremail-Antispam: 1UD129KBjvJXoWxAFyxJr48tr17trWfWr45Jrb_yoWrGF4xpF n8GF43GFWUtr1rCa4UJF4ku3s3Kwn7JFW7KwnxX34fAF13Za4qkFyjka98Z34YqryDurW5 ZFs093yxZFnrAFUanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUU9Kb4IE77IF4wAFF20E14v26rWj6s0DM7CY07I20VC2zVCF04k2 6cxKx2IYs7xG6rWj6s0DM7CIcVAFz4kK6r1j6r18M28IrcIa0xkI8VA2jI8067AKxVWUXw A2048vs2IY020Ec7CjxVAFwI0_Gr0_Xr1l8cAvFVAK0II2c7xJM28CjxkF64kEwVA0rcxS w2x7M28EF7xvwVC0I7IYx2IY67AKxVWDJVCq3wA2z4x0Y4vE2Ix0cI8IcVCY1x0267AKxV W8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK6I8E87Iv6xkF7I0E14v2 6rxl6s0DM2AIxVAIcxkEcVAq07x20xvEncxIr21l5I8CrVACY4xI64kE6c02F40Ex7xfMc Ij6xIIjxv20xvE14v26r106r15McIj6I8E87Iv67AKxVWUJVW8JwAm72CE4IkC6x0Yz7v_ Jr0_Gr1lF7xvr2IYc2Ij64vIr41lc7CjxVAaw2AFwI0_JF0_Jw1l42xK82IYc2Ij64vIr4 1l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK 67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r1q6r43MIIYrxkI7VAKI48JMIIF0xvE2Ix0cI 8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAv wI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14 v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjxU2FApUUUUU X-CM-SenderInfo: hfkh02xlgr0w46kxt4xhlfz01xgou0bp/ Content-Type: text/plain; charset="utf-8" From: Chen Ridong The remote_children list is used to track all remote partitions attached to a cpuset. However, it serves no other purpose. Using a boolean flag to indicate whether a cpuset is a remote partition is a more direct approach, making remote_children unnecessary. This patch replaces the list with a remote_partition flag in the cpuset structure and removes remote_children entirely. Signed-off-by: Chen Ridong --- kernel/cgroup/cpuset-internal.h | 4 ++-- kernel/cgroup/cpuset.c | 14 +++++--------- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/kernel/cgroup/cpuset-internal.h b/kernel/cgroup/cpuset-interna= l.h index 5cac42c5fd97..7308e8bc4dde 100644 --- a/kernel/cgroup/cpuset-internal.h +++ b/kernel/cgroup/cpuset-internal.h @@ -172,8 +172,8 @@ struct cpuset { /* Handle for cpuset.cpus.partition */ struct cgroup_file partition_file; =20 - /* Remote partition silbling list anchored at remote_children */ - struct list_head remote_sibling; + /* Whether cpuset is a remote partition */ + bool remote_partition; =20 /* Used to merge intersecting subsets for generate_sched_domains */ struct uf_node node; diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c index c90476d52f09..c357bfb69fe2 100644 --- a/kernel/cgroup/cpuset.c +++ b/kernel/cgroup/cpuset.c @@ -94,9 +94,6 @@ static bool isolated_cpus_updating; static cpumask_var_t boot_hk_cpus; static bool have_boot_isolcpus; =20 -/* List of remote partition root children */ -static struct list_head remote_children; - /* * A flag to force sched domain rebuild at the end of an operation. * It can be set in @@ -219,7 +216,7 @@ static struct cpuset top_cpuset =3D { BIT(CS_MEM_EXCLUSIVE) | BIT(CS_SCHED_LOAD_BALANCE), .partition_root_state =3D PRS_ROOT, .relax_domain_level =3D -1, - .remote_sibling =3D LIST_HEAD_INIT(top_cpuset.remote_sibling), + .remote_partition =3D false, }; =20 /* @@ -1572,7 +1569,7 @@ static int compute_trialcs_excpus(struct cpuset *tria= lcs, struct cpuset *cs) =20 static inline bool is_remote_partition(struct cpuset *cs) { - return !list_empty(&cs->remote_sibling); + return cs->remote_partition; } =20 static inline bool is_local_partition(struct cpuset *cs) @@ -1621,7 +1618,7 @@ static int remote_partition_enable(struct cpuset *cs,= int new_prs, =20 spin_lock_irq(&callback_lock); partition_xcpus_add(new_prs, NULL, tmp->new_cpus); - list_add(&cs->remote_sibling, &remote_children); + cs->remote_partition =3D true; cpumask_copy(cs->effective_xcpus, tmp->new_cpus); spin_unlock_irq(&callback_lock); update_isolation_cpumasks(); @@ -1651,7 +1648,7 @@ static void remote_partition_disable(struct cpuset *c= s, struct tmpmasks *tmp) WARN_ON_ONCE(!cpumask_subset(cs->effective_xcpus, subpartitions_cpus)); =20 spin_lock_irq(&callback_lock); - list_del_init(&cs->remote_sibling); + cs->remote_partition =3D false; partition_xcpus_del(cs->partition_root_state, NULL, cs->effective_xcpus); if (cs->prs_err) cs->partition_root_state =3D -cs->partition_root_state; @@ -3603,7 +3600,7 @@ cpuset_css_alloc(struct cgroup_subsys_state *parent_c= ss) __set_bit(CS_SCHED_LOAD_BALANCE, &cs->flags); fmeter_init(&cs->fmeter); cs->relax_domain_level =3D -1; - INIT_LIST_HEAD(&cs->remote_sibling); + cs->remote_partition =3D false; =20 /* Set CS_MEMORY_MIGRATE for default hierarchy */ if (cpuset_v2()) @@ -3874,7 +3871,6 @@ int __init cpuset_init(void) nodes_setall(top_cpuset.effective_mems); =20 fmeter_init(&top_cpuset.fmeter); - INIT_LIST_HEAD(&remote_children); =20 BUG_ON(!alloc_cpumask_var(&cpus_attach, GFP_KERNEL)); =20 --=20 2.34.1 From nobody Mon Feb 9 05:06:01 2026 Received: from dggsgout12.his.huawei.com (dggsgout12.his.huawei.com [45.249.212.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DCBD02747B; Mon, 10 Nov 2025 02:07:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.56 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; cv=none; b=jZwfWyZvd0mAmDRRMqwKYwIQtP3/y13UNDX/ZISkx/2lAs6o01UklhtY87nhVcrYctcBPf0HjpKT51yHboNPRdiLdpFErpgUihRYDXWKdF1MwfHM/frM99F1MA+Vt4rRkwLqf8tXwtQ6JxbDNmn54TbfuSM/ji6J22HIcxklYmQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762740463; c=relaxed/simple; bh=X2I1F/yDa7DktzrVXLN/G9326ra+lTHr8o2fcN0+B6w=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=pkoVKAfgtFxNPptRLMKsn3SRs/g0symxZoir6b8mkW7+hLl7jJwhygpAGK+l7ccrpENM1+dtGWGI25IntovyqdLKvYM2sJMNJbOBymlTt2zd3oCnJiOqPdEL0D4KQZRZ5EDdO+XYPswZ7fjnB3j3gj6gxqkB7F6DHVB6GBmHcCs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com; spf=pass smtp.mailfrom=huaweicloud.com; arc=none smtp.client-ip=45.249.212.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huaweicloud.com Received: from mail.maildlp.com (unknown [172.19.93.142]) by dggsgout12.his.huawei.com (SkyGuard) with ESMTPS id 4d4Y2Z4K56zKHMWF; Mon, 10 Nov 2025 10:07:18 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id 8E22C1A084D; Mon, 10 Nov 2025 10:07:32 +0800 (CST) Received: from hulk-vt.huawei.com (unknown [10.67.174.121]) by APP1 (Coremail) with SMTP id cCh0CgBXkUrUSBFpPBDaAA--.6382S5; Mon, 10 Nov 2025 10:07:32 +0800 (CST) From: Chen Ridong To: longman@redhat.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: [PATCH -next 3/3] cpuset: remove need_rebuild_sched_domains Date: Mon, 10 Nov 2025 01:52:28 +0000 Message-Id: <20251110015228.897736-4-chenridong@huaweicloud.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20251110015228.897736-1-chenridong@huaweicloud.com> References: <20251110015228.897736-1-chenridong@huaweicloud.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: cCh0CgBXkUrUSBFpPBDaAA--.6382S5 X-Coremail-Antispam: 1UD129KBjvJXoW7KrW5tryDGw47ZF4xWF4fAFb_yoW8Jw48pF 1kua1jq3yjqr1Uuw4DAa9rur93Ka9Fvasrt3s8G3s2qF17K3W2g3Wjg3W3Jr9a9rn7uF13 AFsFk3y2qF1jyrJanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUU9Kb4IE77IF4wAFF20E14v26rWj6s0DM7CY07I20VC2zVCF04k2 6cxKx2IYs7xG6rWj6s0DM7CIcVAFz4kK6r1j6r18M28IrcIa0xkI8VA2jI8067AKxVWUWw A2048vs2IY020Ec7CjxVAFwI0_Xr0E3s1l8cAvFVAK0II2c7xJM28CjxkF64kEwVA0rcxS w2x7M28EF7xvwVC0I7IYx2IY67AKxVWDJVCq3wA2z4x0Y4vE2Ix0cI8IcVCY1x0267AKxV W8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK6I8E87Iv6xkF7I0E14v2 6rxl6s0DM2AIxVAIcxkEcVAq07x20xvEncxIr21l5I8CrVACY4xI64kE6c02F40Ex7xfMc Ij6xIIjxv20xvE14v26r106r15McIj6I8E87Iv67AKxVWUJVW8JwAm72CE4IkC6x0Yz7v_ Jr0_Gr1lF7xvr2IYc2Ij64vIr41lc7CjxVAaw2AFwI0_JF0_Jw1l42xK82IYc2Ij64vIr4 1l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK 67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r1q6r43MIIYrxkI7VAKI48JMIIF0xvE2Ix0cI 8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAv wI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14 v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjxUrbyCDUUUU X-CM-SenderInfo: hfkh02xlgr0w46kxt4xhlfz01xgou0bp/ Content-Type: text/plain; charset="utf-8" From: Chen Ridong 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 Reviewed-by: Waiman Long --- 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, s= truct tmpmasks *tmp, { struct cpuset *cp; struct cgroup_subsys_state *pos_css; - bool need_rebuild_sched_domains =3D false; int old_prs, new_prs; =20 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 =3D true; + cpuset_force_rebuild(); =20 rcu_read_lock(); css_put(&cp->css); } rcu_read_unlock(); - - if (need_rebuild_sched_domains) - cpuset_force_rebuild(); } =20 /** --=20 2.34.1