From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752225AbdFUViM (ORCPT ); Wed, 21 Jun 2017 17:38:12 -0400 Received: from mail-yw0-f195.google.com ([209.85.161.195]:35739 "EHLO mail-yw0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751487AbdFUViK (ORCPT ); Wed, 21 Jun 2017 17:38:10 -0400 Date: Wed, 21 Jun 2017 17:38:07 -0400 From: Tejun Heo To: Waiman Long Cc: Li Zefan , Johannes Weiner , Peter Zijlstra , Ingo Molnar , cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com, pjt@google.com, luto@amacapital.net, efault@gmx.de, torvalds@linux-foundation.org Subject: Re: [RFC PATCH-cgroup 4/6] cgroup: Introduce subtree root mode Message-ID: <20170621213807.GC14720@htj.duckdns.org> References: <1497452737-11125-1-git-send-email-longman@redhat.com> <1497452737-11125-5-git-send-email-longman@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1497452737-11125-5-git-send-email-longman@redhat.com> User-Agent: Mutt/1.8.2 (2017-04-18) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, Waiman. On Wed, Jun 14, 2017 at 11:05:35AM -0400, Waiman Long wrote: > Subtree root mode is a new cgroup mode which applies the following > restrictions when turned on: > > 1) Controllers are only allowed to be passed to the children in > bypass mode except those with the "enable_on_root" flag on. > 2) Only 1 child cgroup is allowed. > > That lone child can be used as the pseudo root of a container cgroup > hierarchy. All the resources, if controlled, are in the parent > cgroup. There will be no control knobs in the child. That makes it > look and feel like a root. I'm not sure not having the control files in the child makes that much difference. > That pseudo root is also considered to be mixable and so can become > root of a mixed threaded subtree. The no internal process constraint > also does not apply. Heh, you can't just declare a non-root cgroup to be a mixed root but if you're special casing this and making the kernel play a masquerade with special node, you can make cgroup provide a mixed root while hosting the internal processes in a dedicated leaf cgroup which isn't visible to the nested root, right? It's all a game of masquerading tho and doesn't actually enable anything which isn't possible now. This would definitely be useful for testing. Thanks. -- tejun