[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aJzWKq81QWCte4MZ@slm.duckdns.org>
Date: Wed, 13 Aug 2025 08:15:06 -1000
From: Tejun Heo <tj@...nel.org>
To: Chen Ridong <chenridong@...weicloud.com>
Cc: hannes@...xchg.org, mkoutny@...e.com, longman@...hat.com,
cgroups@...r.kernel.org, linux-kernel@...r.kernel.org,
lujialin4@...wei.com, chenridong@...wei.com,
christophe.jaillet@...adoo.fr
Subject: Re: [-next v2 1/4] cpuset: remove redundant CS_ONLINE flag
On Wed, Aug 13, 2025 at 08:29:01AM +0000, Chen Ridong wrote:
> From: Chen Ridong <chenridong@...wei.com>
>
> The CS_ONLINE flag was introduced prior to the CSS_ONLINE flag in the
> cpuset subsystem. Currently, the flag setting sequence is as follows:
>
> 1. cpuset_css_online() sets CS_ONLINE
> 2. css->flags gets CSS_ONLINE set
> ...
> 3. cgroup->kill_css sets CSS_DYING
> 4. cpuset_css_offline() clears CS_ONLINE
> 5. css->flags clears CSS_ONLINE
>
> The is_cpuset_online() check currently occurs between steps 1 and 3.
> However, it would be equally safe to perform this check between steps 2
> and 3, as CSS_ONLINE provides the same synchronization guarantee as
> CS_ONLINE.
>
> Since CS_ONLINE is redundant with CSS_ONLINE and provides no additional
> synchronization benefits, we can safely remove it to simplify the code.
>
> Signed-off-by: Chen Ridong <chenridong@...wei.com>
> Acked-by: Waiman Long <longman@...hat.com>
Applied to cgroup/for-6.18.
Thanks.
--
tejun
Powered by blists - more mailing lists