cgroup: reorder the operations in cgroup_destroy_locked()
authorTejun Heo <tj@kernel.org>
Fri, 14 Jun 2013 02:27:41 +0000 (19:27 -0700)
committerTejun Heo <tj@kernel.org>
Fri, 14 Jun 2013 02:27:41 +0000 (19:27 -0700)
commit455050d23e1bfc47ca98e943ad5b2f3a9bbe45fb
tree690eb75fb11a1869aa5092fe29bb61be0a641fd8
parent6f3d828f0fb7fdaffc6f32cb8a1cb7fcf8824598
cgroup: reorder the operations in cgroup_destroy_locked()

This patch reorders the operations in cgroup_destroy_locked() such
that the userland visible parts happen before css offlining and
removal from the ->sibling list.  This will be used to make css use
percpu refcnt.

While at it, split out CGRP_DEAD related comment from the refcnt
deactivation one and correct / clarify how different guarantees are
met.

While this patch changes the specific order of operations, it
shouldn't cause any noticeable behavior difference.

Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Li Zefan <lizefan@huawei.com>
kernel/cgroup.c