]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
cgroup: Replace the css_set call with cgroup_get
authorGaosheng Cui <cuigaosheng1@huawei.com>
Fri, 2 Jun 2023 07:43:46 +0000 (15:43 +0800)
committerTejun Heo <tj@kernel.org>
Mon, 5 Jun 2023 19:42:42 +0000 (09:42 -1000)
We will release the refcnt of cgroup via cgroup_put, for example
in the cgroup_lock_and_drain_offline function, so replace css_get
with the cgroup_get function for better readability.

Signed-off-by: Gaosheng Cui <cuigaosheng1@huawei.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
kernel/cgroup/cgroup.c

index eb3d9c1f25e30d07b1fb9eff2d9cbb09d38d2a25..f69e9a443ecc358fa0c9486163883ca198f07197 100644 (file)
@@ -619,7 +619,7 @@ EXPORT_SYMBOL_GPL(cgroup_get_e_css);
 static void cgroup_get_live(struct cgroup *cgrp)
 {
        WARN_ON_ONCE(cgroup_is_dead(cgrp));
-       css_get(&cgrp->self);
+       cgroup_get(cgrp);
 }
 
 /**