From: Li Zefan Date: Wed, 17 Sep 2014 10:18:34 +0000 (+0800) Subject: cgroup: remove redundant code in cgroup_rmdir() X-Git-Tag: firefly_0821_release~176^2~3097^2~10 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=244bb9a6336d2aa53526261ec35c593ebd5c1a33;p=firefly-linux-kernel-4.4.55.git cgroup: remove redundant code in cgroup_rmdir() We no longer clear kn->priv in cgroup_rmdir(), so we don't need to get an extra refcnt. Signed-off-by: Zefan Li Signed-off-by: Tejun Heo --- diff --git a/kernel/cgroup.c b/kernel/cgroup.c index 619aae399a3a..d739a732edb9 100644 --- a/kernel/cgroup.c +++ b/kernel/cgroup.c @@ -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; }