linux-stable/kernel/cgroup
Yafang Shao dd9542ae7c cgroup: Make operations on the cgroup root_list RCU safe
commit d23b5c5777 upstream.

At present, when we perform operations on the cgroup root_list, we must
hold the cgroup_mutex, which is a relatively heavyweight lock. In reality,
we can make operations on this list RCU-safe, eliminating the need to hold
the cgroup_mutex during traversal. Modifications to the list only occur in
the cgroup root setup and destroy paths, which should be infrequent in a
production environment. In contrast, traversal may occur frequently.
Therefore, making it RCU-safe would be beneficial.

Signed-off-by: Yafang Shao <laoar.shao@gmail.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
To: Michal Koutný <mkoutny@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-08-19 06:04:25 +02:00
..
cgroup-internal.h cgroup: Make operations on the cgroup root_list RCU safe 2024-08-19 06:04:25 +02:00
cgroup-v1.c kernfs: Convert kernfs_path_from_node_locked() from strlcpy() to strscpy() 2024-08-03 08:53:21 +02:00
cgroup.c cgroup: Make operations on the cgroup root_list RCU safe 2024-08-19 06:04:25 +02:00
cpuset.c cgroup/cpuset: Prevent UAF in proc_cpuset_show() 2024-08-03 08:53:22 +02:00
debug.c
freezer.c cgroup: cleanup comments 2022-03-13 19:19:27 -10:00
legacy_freezer.c cgroup_freezer: cgroup_freezing: Check if not frozen 2023-12-13 18:45:22 +01:00
Makefile
misc.c cgroup/misc: Store atomic64_t reads to u64 2023-07-21 08:10:06 -10:00
namespace.c cgroup:namespace: Remove unused cgroup_namespaces_init() 2023-08-14 14:29:47 -10:00
pids.c cgroup: add pids.peak interface for pids controller 2022-09-04 09:26:51 -10:00
rdma.c rdmacg: fix kernel-doc warnings in rdmacg 2023-06-05 09:45:14 -10:00
rstat.c cgroup/rstat: Record the cumulative per-cpu time of cgroup and its descendants 2023-08-07 08:41:25 -10:00