• Tejun Heo's avatar
    cgroup: fix cgroup post-order descendant walk of empty subtree · 58b79a91
    Tejun Heo authored
    bd8815a6 ("cgroup: make css_for_each_descendant() and friends
    include the origin css in the iteration") updated cgroup descendant
    iterators to include the origin css; unfortuantely, it forgot to drop
    special case handling in css_next_descendant_post() for empty subtree
    leading to failure to visit the origin css without any child.
    
    Fix it by dropping the special case handling and always returning the
    leftmost descendant on the first iteration.
    Signed-off-by: default avatarTejun Heo <tj@kernel.org>
    Acked-by: default avatarLi Zefan <lizefan@huawei.com>
    58b79a91
cgroup.c 158 KB