aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/util/c++/clang.cpp
diff options
context:
space:
mode:
authorShakeel Butt <shakeelb@google.com>2021-10-24 23:19:14 -0700
committerTejun Heo <tj@kernel.org>2021-10-25 07:23:31 -1000
commitbe288169712f3dea0bc6b50c00b3ab53d85f1435 (patch)
tree1a92e683510d3ea9ba8aa49535d67f96893149fd /tools/perf/util/c++/clang.cpp
parent0061270307f2ad5fa01db1ac5f1da0e83410adaf (diff)
cgroup: reduce dependency on cgroup_mutex
Currently cgroup_get_from_path() and cgroup_get_from_id() grab cgroup_mutex before traversing the default hierarchy to find the kernfs_node corresponding to the path/id and then extract the linked cgroup. Since cgroup_mutex is still held, it is guaranteed that the cgroup will be alive and the reference can be taken on it. However similar guarantee can be provided without depending on the cgroup_mutex and potentially reducing avenues of cgroup_mutex contentions. The kernfs_node's priv pointer is RCU protected pointer and with just rcu read lock we can grab the reference on the cgroup without cgroup_mutex. So, remove cgroup_mutex from them. Signed-off-by: Shakeel Butt <shakeelb@google.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/util/c++/clang.cpp')
0 files changed, 0 insertions, 0 deletions