From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751128AbdFYE1W (ORCPT ); Sun, 25 Jun 2017 00:27:22 -0400 Received: from mail-qt0-f195.google.com ([209.85.216.195]:36575 "EHLO mail-qt0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750944AbdFYE1U (ORCPT ); Sun, 25 Jun 2017 00:27:20 -0400 Date: Sun, 25 Jun 2017 00:27:17 -0400 From: Tejun Heo To: Li Zefan , Johannes Weiner Cc: cgroups@vger.kernel.org, Aravind Anbudurai , linux-kernel@vger.kernel.org Subject: [1/3] cgroup: "cgroup.subtree_control" should be writeable by delegatee Message-ID: <20170625042717.GA14158@htj.duckdns.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline 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 "cgroup.subtree_control" determines which resource types a cgroup wants to control. Unlike actual resource knobs, this is an attribute which belongs to the cgroup itself instead of its parent and thus should be writeable by the delegatee in a delegated cgroup. Update delegation documentation accordingly. Signed-off-by: Tejun Heo --- Documentation/cgroup-v2.txt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) --- a/Documentation/cgroup-v2.txt +++ b/Documentation/cgroup-v2.txt @@ -309,10 +309,11 @@ file. 2-5-1. Model of Delegation A cgroup can be delegated to a less privileged user by granting write -access of the directory and its "cgroup.procs" file to the user. Note -that resource control interface files in a given directory control the -distribution of the parent's resources and thus must not be delegated -along with the directory. +access of the directory and its "cgroup.procs" and +"cgroup.subtree_control" files to the user. Note that resource +control interface files in a given directory control the distribution +of the parent's resources and thus must not be delegated along with +the directory. Once delegated, the user can build sub-hierarchy under the directory, organize processes as it sees fit and further distribute the resources