[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <cover.1757326641.git.escape@linux.alibaba.com>
Date: Mon, 8 Sep 2025 18:20:26 +0800
From: Yi Tao <escape@...ux.alibaba.com>
To: tj@...nel.org,
hannes@...xchg.org,
mkoutny@...e.com
Cc: cgroups@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH v3 0/1] cgroup: replace global percpu_rwsem with per threadgroup resem when writing to cgroup.procs
Changes in v3:
- Expend commit log and comments.
- Put argument @tsk at end in cgroup_attach_lock/unlock.
- down_write global cgroup_thread_rwsem when flipping favordynmods to
synchronize with task between cgroup_threadgroup_change_begin and end.
- Rename group_rwsem to cgroup_threadgroup_rwsem.
- Fix bug causing abnormal cgroup migration due to threadgroup leader changes。
Changes in v2:
- Use favordynmods as the enabling switch.
- Determine whether to use the per-thread-group rwsem based on whether
the task is NULL.
- Fix system hang caused by acquiring cgroup_threadgroup_rwsem inside
rcu_read_lock.
Yi Tao (1):
cgroup: replace global percpu_rwsem with per threadgroup resem when
writing to cgroup.procs
include/linux/cgroup-defs.h | 12 +++-
include/linux/sched/signal.h | 4 ++
init/init_task.c | 3 +
kernel/cgroup/cgroup-internal.h | 4 +-
kernel/cgroup/cgroup-v1.c | 8 +--
kernel/cgroup/cgroup.c | 105 ++++++++++++++++++++++----------
kernel/fork.c | 4 ++
7 files changed, 101 insertions(+), 39 deletions(-)
--
2.32.0.3.g01195cf9f
Powered by blists - more mailing lists