cgroup: remove cgroup_mutex from cgroupstats_build
authorShakeel Butt <shakeelb@google.com>
Mon, 25 Oct 2021 06:19:15 +0000 (23:19 -0700)
committerTejun Heo <tj@kernel.org>
Mon, 25 Oct 2021 17:24:03 +0000 (07:24 -1000)
commitbb758421416fd8af2267a8e07d53fb8328b07c4e
tree9b7bf563e49231c6e4a77611a572277a07f1faa0
parentbe288169712f3dea0bc6b50c00b3ab53d85f1435
cgroup: remove cgroup_mutex from cgroupstats_build

The function cgroupstats_build extracts cgroup from the kernfs_node's
priv pointer which is a RCU pointer. So, there is no need to grab
cgroup_mutex. Just get the reference on the cgroup before using and
remove the cgroup_mutex altogether.

Signed-off-by: Shakeel Butt <shakeelb@google.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
kernel/cgroup/cgroup-v1.c