diff options
author | Tejun Heo <tj@kernel.org> | 2013-11-29 10:42:59 -0500 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2013-11-29 10:42:59 -0500 |
commit | 069df3b7aeb3f4e926c4da9630c92010909af512 (patch) | |
tree | 75e84d904908603d009824bb8cb43315e2683b7f /kernel/ksysfs.c | |
parent | e6b817103d168a76e4044ebcdbc08225d77a81cb (diff) |
cgroup: remove cgroup_pidlist->rwsem
cgroup_pidlist locking is needlessly complicated. It has outer
cgroup->pidlist_mutex to protect the list of pidlists associated with
a cgroup and then each pidlist has rwsem to synchronize updates and
reads. Given that the only read access is from seq_file operations
which are always invoked back-to-back, the rwsem is a giant overkill.
All it does is adding unnecessary complexity.
This patch removes cgroup_pidlist->rwsem and protects all accesses to
pidlists belonging to a cgroup with cgroup->pidlist_mutex.
pidlist->rwsem locking is removed if it's nested inside
cgroup->pidlist_mutex; otherwise, it's replaced with
cgroup->pidlist_mutex locking.
Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Li Zefan <lizefan@huawei.com>
Diffstat (limited to 'kernel/ksysfs.c')
0 files changed, 0 insertions, 0 deletions