Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-15 Thread Michal Hocko
On Sun 11-01-15 15:55:43, Johannes Weiner wrote: > From d527ba1dbfdb58e1f7c7c4ee12b32ef2e5461990 Mon Sep 17 00:00:00 2001 > From: Johannes Weiner > Date: Sun, 11 Jan 2015 10:29:05 -0500 > Subject: [patch] mm: memcontrol: zap outstanding cache/swap references during > unbind > > Cgroup core

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-15 Thread Michal Hocko
On Sat 10-01-15 16:43:16, Tejun Heo wrote: > Currently, if a hierarchy doesn't have any live children when it's > unmounted, the hierarchy starts dying by killing its refcnt. The > expectation is that even if there are lingering dead children which > are lingering due to remaining references,

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-15 Thread Michal Hocko
On Sun 11-01-15 15:55:43, Johannes Weiner wrote: From d527ba1dbfdb58e1f7c7c4ee12b32ef2e5461990 Mon Sep 17 00:00:00 2001 From: Johannes Weiner han...@cmpxchg.org Date: Sun, 11 Jan 2015 10:29:05 -0500 Subject: [patch] mm: memcontrol: zap outstanding cache/swap references during unbind

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-15 Thread Michal Hocko
On Sat 10-01-15 16:43:16, Tejun Heo wrote: Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children which are lingering due to remaining references, they'll

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-14 Thread Suzuki K. Poulose
On 11/01/15 20:55, Johannes Weiner wrote: On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-14 Thread Suzuki K. Poulose
On 11/01/15 20:55, Johannes Weiner wrote: On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-12 Thread Tejun Heo
On Mon, Jan 12, 2015 at 03:59:56PM +0300, Vladimir Davydov wrote: > I haven't dug deep into the cgroup core, but may be we could detach the > old root in cgroup_kill_sb() and leave it dangling until the last > reference to it has gone? The root isn't the problem here. Individual controllers are

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-12 Thread Vladimir Davydov
On Mon, Jan 12, 2015 at 06:28:45AM -0500, Tejun Heo wrote: > On Mon, Jan 12, 2015 at 11:01:14AM +0300, Vladimir Davydov wrote: > > Come to think of it, I wonder how many users actually want to mount > > different controllers subset after unmount. Because we could allow > > It wouldn't be a common

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-12 Thread Tejun Heo
Hello, Vladimir. On Mon, Jan 12, 2015 at 11:01:14AM +0300, Vladimir Davydov wrote: > Come to think of it, I wonder how many users actually want to mount > different controllers subset after unmount. Because we could allow It wouldn't be a common use case but, on the face of it, we still support

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-12 Thread Vladimir Davydov
On Sun, Jan 11, 2015 at 03:55:43PM -0500, Johannes Weiner wrote: > On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: > > > May be, we should kill the ref counter to the memory controller root in > > > cgroup_kill_sb only if there is no children at all, neither online nor > > > offline. >

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-12 Thread Vladimir Davydov
On Sun, Jan 11, 2015 at 03:55:43PM -0500, Johannes Weiner wrote: On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: May be, we should kill the ref counter to the memory controller root in cgroup_kill_sb only if there is no children at all, neither online nor offline. Ah,

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-12 Thread Tejun Heo
On Mon, Jan 12, 2015 at 03:59:56PM +0300, Vladimir Davydov wrote: I haven't dug deep into the cgroup core, but may be we could detach the old root in cgroup_kill_sb() and leave it dangling until the last reference to it has gone? The root isn't the problem here. Individual controllers are as

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-12 Thread Tejun Heo
Hello, Vladimir. On Mon, Jan 12, 2015 at 11:01:14AM +0300, Vladimir Davydov wrote: Come to think of it, I wonder how many users actually want to mount different controllers subset after unmount. Because we could allow It wouldn't be a common use case but, on the face of it, we still support

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-12 Thread Vladimir Davydov
On Mon, Jan 12, 2015 at 06:28:45AM -0500, Tejun Heo wrote: On Mon, Jan 12, 2015 at 11:01:14AM +0300, Vladimir Davydov wrote: Come to think of it, I wonder how many users actually want to mount different controllers subset after unmount. Because we could allow It wouldn't be a common use

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-11 Thread Johannes Weiner
On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: > Currently, if a hierarchy doesn't have any live children when it's > unmounted, the hierarchy starts dying by killing its refcnt. The > expectation is that even if there are lingering dead children which > are lingering due to remaining

Re: [PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-11 Thread Johannes Weiner
On Sat, Jan 10, 2015 at 04:43:16PM -0500, Tejun Heo wrote: Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children which are lingering due to remaining

[PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys->unbind() callback

2015-01-10 Thread Tejun Heo
Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children which are lingering due to remaining references, they'll be put in a finite amount of time. When the

[PATCH cgroup/for-3.19-fixes] cgroup: implement cgroup_subsys-unbind() callback

2015-01-10 Thread Tejun Heo
Currently, if a hierarchy doesn't have any live children when it's unmounted, the hierarchy starts dying by killing its refcnt. The expectation is that even if there are lingering dead children which are lingering due to remaining references, they'll be put in a finite amount of time. When the