Skip to content

Commit

Permalink
cgroup: remove redundant code in cgroup_rmdir()
Browse files Browse the repository at this point in the history
We no longer clear kn->priv in cgroup_rmdir(), so we don't need
to get an extra refcnt.

Signed-off-by: Zefan Li <lizefan@huawei.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
  • Loading branch information
Li Zefan authored and Tejun Heo committed Sep 17, 2014
1 parent 6213daa commit 244bb9a
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions kernel/cgroup.c
Original file line number Diff line number Diff line change
Expand Up @@ -4841,13 +4841,10 @@ static int cgroup_rmdir(struct kernfs_node *kn)
cgrp = cgroup_kn_lock_live(kn);
if (!cgrp)
return 0;
cgroup_get(cgrp); /* for @kn->priv clearing */

ret = cgroup_destroy_locked(cgrp);

cgroup_kn_unlock(kn);

cgroup_put(cgrp);
return ret;
}

Expand Down

0 comments on commit 244bb9a

Please sign in to comment.