Re: [PATCH 3/8] cgroup: use cgroup_lock_live_group(parent) in cgroup_create()

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

 



Hey, Michal.

On Thu, Nov 1, 2012 at 2:16 AM, Michal Hocko <mhocko@xxxxxxx> wrote:
> I am not sure I understand. What does deactivate_super has to do with
> the above suggestion? cgroup_lock_live_group will take the cgroup_mutex
> on the success or frees the previously allocated&unused memory. The
> only thing I was suggesting is to do cgroup_lock_live_group first and
> allocate the cgroup only if it doesn't fail.

It complicates updates to the error exit path. You end up having to
update a lot more and it's not like grabbing lock first is
substantially better in any way, so why bother?

Thanks.

-- 
tejun
_______________________________________________
Containers mailing list
Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/containers


[Index of Archives]     [Cgroups]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux