Re: [PATCH 1/8] cgroup: kill cgroup_subsys->__DEPRECATED_clear_css_refs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey, Michal.

On Wed, Oct 31, 2012 at 03:37:51PM +0100, Michal Hocko wrote:
> > +	for_each_subsys(cgrp->root, ss)
> > +		if (ss->pre_destroy)
> > +			WARN_ON_ONCE(ss->pre_destroy(cgrp));
> 
> Hmm, I am not sure I like this WARN_ON_ONCE. First it can happen for
> more than one controller and second we can just clear CGRP_WAIT_ON_RMDIR
> and return with EBUSY. The only possible failure at the moment is when a
> new task or a child group appear.
> I know it is not a big deal because it will disappear later in the
> series but it would be more readable IMO.

The WARN_ON_ONCE() is just moved from the original
cgroup_call_pre_destroy().  We can add an error out there but that
makes future changes difficult.  It's a chicken and egg problem.  You
gotta break the loop somewhere.

Thanks.

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe cgroups" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [Monitors]

  Powered by Linux