cgroup: update comment about dropping cgroup kn refs
PATCH 1/1 cgroup: update comment about dropping cgroup kn refs
the cgroup is actually freed in css_free_rwork_fn() now the ref count of the cgroup's kernfs_node is also dropped there so we need to update the corresponding comment in cgroup_mkdir()
--- kernel/cgroup/cgroup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/cgroup/cgroup.c +1 -1
@@ -5835,7 +5835,7 @@ int cgroup_mkdir(struct kernfs_node *parent_kn, const char *name, umode_t mode) }/* -* This extra ref will be put in cgroup_free_fn() and guarantees +* This extra ref will be put in css_free_rwork_fn() and guarantees * that @cgrp->kn is always accessible. */ kernfs_get (cgrp->kn);
Signature · 1 line
2.47.1
Michal Koutný
maintainerHello Haorui.
Quoted 3 lines · Haorui He
the cgroup is actually freed in
css_free_rwork_fn()now the ref count of the cgroup'skernfs_nodeis also dropped there so we need to update the corresponding comment incgroup_mkdir()
It seems you've read through the comments recently.
Do you have more up your sleeve? (So that it could be grouped in one comments changeset.)
Thanks,
Michal
Hello Michal.
Quoted 3 lines · Michal Koutný
It seems you've read through the comments recently.
Do you have more up your sleeve? (So that it could be grouped in one comments changeset.)
No, I have not find more right now. I'm just reading the cgroups code and happen to be confused by that comment. I'm still reading about the cgroups code base though, so I'm not sure whether I will find more places that need to be updated.
Thanks,
Haorui He
Quoted 5 lines · Haorui He
the cgroup is actually freed in
css_free_rwork_fn()now the ref count of the cgroup'skernfs_nodeis also dropped there so we need to update the corresponding comment incgroup_mkdir()Signed-off-by Haorui He <[email protected]>
Applied to sched_ext/for-6.14.
Thanks.
Signature · 1 line
tejun