On Tue, Aug 02, 2016 at 02:42:32PM +0200, Michal Hocko wrote:
> 
> On Mon 01-08-16 16:26:24, Vladimir Davydov wrote:
> [...]
> > +static struct mem_cgroup *mem_cgroup_id_get_active(struct mem_cgroup 
> > *memcg)
> > +{
> > +   while (!atomic_inc_not_zero(&memcg->id.ref))
> > +           memcg = parent_mem_cgroup(memcg);
> > +   return memcg;
> > +}
> 
> Does this actually work properly? Say we have root -> A so parent is
> NULL if root (use_hierarchy == false).

Yeah, I completely forgot about the !use_hierarchy case. Thanks for
catching this. I'll fix and resend.

Reply via email to