lkml.org 
[lkml]   [2009]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC][PATCH 5/4] memcg: don't call res_counter_uncharge when obsolete
* KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> [2009-01-15 14:14:58]:

> On Thu, 15 Jan 2009 13:38:14 +0900
> Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> wrote:
>
> > On Thu, 15 Jan 2009 11:14:20 +0900, Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> wrote:
> > > > > > To handle the problem "parent may be obsolete",
> > > > > >
> > > > > > call mem_cgroup_get(parent) at create()
> > > > > > call mem_cgroup_put(parent) at freeing memcg.
> > > > > > (regardless of use_hierarchy.)
> > > > > >
> > > > > > is clearer way to go, I think.
> > > > > >
> > > > > > I wonder whether there is mis-accounting problem or not..
> > > > > >
> > hmm, after more consideration, although this patch can prevent the BUG,
> > it can leak memsw accounting of parents because memsw of parents, which
> > have been incremented by charge, does not decremented.
> >
> > I'll try pet/put parent approach..
> > Or any other good ideas ?
> >
> >
> I believe get/put at create/destroy is enough now..
> Let's try and see what happens.
>

Other approach could be get_hierarchical/put_hierarchical, but that
can quickly get complex. Let us try and avoid it, unless nothing else
works.

--
Balbir


\
 
 \ /
  Last update: 2009-01-15 06:59    [W:0.116 / U:0.316 seconds]
©2003-2014 Jasper Spaans. Advertise on this site