Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754173AbcJDQQf (ORCPT ); Tue, 4 Oct 2016 12:16:35 -0400 Received: from mail-yw0-f196.google.com ([209.85.161.196]:33681 "EHLO mail-yw0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753332AbcJDQQd (ORCPT ); Tue, 4 Oct 2016 12:16:33 -0400 Date: Tue, 4 Oct 2016 12:16:30 -0400 From: Tejun Heo To: John Stultz Cc: lkml , Li Zefan , Jonathan Corbet , cgroups@vger.kernel.org, Android Kernel Team , Rom Lemarchand , Colin Cross , Dmitry Shmidt , Todd Kjos , Christian Poetzsch , Amit Pundir Subject: Re: [RFC][PATCH 0/2] Another pass at Android style loosening of cgroup attach permissions Message-ID: <20161004161630.GC4205@htj.duckdns.org> References: <1475556090-6278-1-git-send-email-john.stultz@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1475556090-6278-1-git-send-email-john.stultz@linaro.org> User-Agent: Mutt/1.7.0 (2016-08-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 982 Lines: 25 Hello, John. On Mon, Oct 03, 2016 at 09:41:28PM -0700, John Stultz wrote: > The migration of a task from the foreground to background, or to > elevate a task to audio priority, may be done by system service that > does not run as root. So this patch allows processes with CAP_SYS_NICE > to be able to migrate tasks between cgroups. I suspect if there was a > specific cap (CAP_SYS_CHANGE_CGROUP) for this, it would be usable here, > but in its absence, they've overloaded CAP_SYS_NICE for this use. CAP_SYS_RESOURCE won't do? > At first glance, overloading CAP_SYS_NICE seems a bit hackish, but this > shows that there is a active and widely deployed use for different cgroup > attachment rules then what is currently available. I'm curious who issues these migrations. Is that restricted to certain uids? If so, would it work for android if cgroupfs supports ACL so that those uids can be approved via setfacl? That'd be an a lot more generic approach. Thanks. -- tejun