From: Waiman Long Subject: Re: [PATCH v4 4/6] cgroup/cpuset: Allow non-top parent partition root to distribute out all CPUs Date: Wed, 11 Aug 2021 14:46:24 -0400 Message-ID: References: <20210811030607.13824-1-longman@redhat.com> <20210811030607.13824-5-longman@redhat.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1628707588; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=BOILZBJ0R4YxSBlomh5xiyJL3tlxmw5VR/2YYVBHfVY=; b=EwW1Lt7iXin0ZAb0YDhwtWWbqICvcow1T6t8TIqgeW3Ycfjhdzi922VTdJiwbiHaW0D6lo KiPxSoeE3+2kQIULIqK1c0ZlGxHafOYUwdeTAlxaUWRfdYSfAH699RDYx822sQBQX+OBvH pPP5DqI00Tuhdr0k0VS6u5M5lpUaEw0= In-Reply-To: Content-Language: en-US List-ID: Content-Type: text/plain; charset="us-ascii"; format="flowed" To: Tejun Heo , Waiman Long Cc: Zefan Li , Johannes Weiner , Jonathan Corbet , Shuah Khan , cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-kselftest-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Andrew Morton , Roman Gushchin , Phil Auld , Peter Zijlstra , Juri Lelli , Frederic Weisbecker , Marcelo Tosatti , =?UTF-8?Q?Michal_Koutn=c3=bd?= On 8/11/21 2:21 PM, Tejun Heo wrote: > On Wed, Aug 11, 2021 at 02:18:17PM -0400, Waiman Long wrote: >> I don't think that is true. A task can reside anywhere in the cgroup >> hierarchy. I have encountered no problem moving tasks around. > Oh, that shouldn't be happening with controllers enabled. Can you please > share a repro? I have done further testing. Enabling controllers won't prohibit moving a task into a parent cgroup as long as the child cgroups have no tasks. Once the child cgroup has task, moving another task to the parent is not allowed (-EBUSY). Similarly if a parent cgroup has tasks, you can't put new tasks into the child cgroup. I don't realize that we have such constraints as I usually do my testing with a cgroup hierarchy with no tasks initially. Anyway, a new lesson learned. I will try to see how to address that in the patch, but the additional check added is still valid in some special case. Cheers, Longman