lkml.org 
[lkml]   [2017]   [Feb]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCHSET for-4.11] cgroup: implement cgroup v2 thread mode
On Thu, Feb 2, 2017 at 12:06 PM, Tejun Heo <tj@kernel.org> wrote:
> Hello,
>
> This patchset implements cgroup v2 thread mode. It is largely based
> on the discussions that we had at the plumbers last year. Here's the
> rough outline.

I like this, but I have some design questions:

>
> * Thread mode is explicitly enabled on a cgroup by writing "enable"
> into "cgroup.threads" file. The cgroup shouldn't have any child
> cgroups or enabled controllers.

Why do you need to manually turn it on? That is, couldn't it be
automatic based on what controllers are enabled?

>
> * Once enabled, arbitrary sub-hierarchy can be created and threads can
> be put anywhere in the subtree by writing TIDs into "cgroup.threads"
> file. Process granularity and no-internal-process constraint don't
> apply in a threaded subtree.

I'm a bit worried that this conflates two different things. There's
thread support, i.e. allowing individual threads to be placed into
cgroups. There's also more flexible sub-hierarchy support, i.e.
relaxing no-internal-process constraints. For the "cpuacct"
controller, for example, both of these make sense. But what if
someone writes a controller (directio, for example, just to make
something up) for which thread granularity makes sense but relaxing
no-internal-process constraints does not?

--Andy

\
 
 \ /
  Last update: 2017-02-02 22:32    [W:0.177 / U:0.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site