mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
cgroup: freezer: call cgroup_enter_frozen() with preemption disabled in ptrace_stop()
ptrace_stop() does preempt_enable_no_resched() to avoid the preemption,
but after that cgroup_enter_frozen() does spin_lock/unlock and this adds
another preemption point.
Reported-and-tested-by: Bruce Ashfield <[email protected]>
Fixes: 76f969e894 ("cgroup: cgroup v2 freezer")
Cc: [email protected] # v5.2+
Signed-off-by: Oleg Nesterov <[email protected]>
Acked-by: Roman Gushchin <[email protected]>
Signed-off-by: Tejun Heo <[email protected]>
This commit is contained in:
parent
9e208aa06c
commit
937c6b27c7
1 changed files with 1 additions and 1 deletions
|
|
@ -2205,8 +2205,8 @@ static void ptrace_stop(int exit_code, int why, int clear_code, kernel_siginfo_t
|
|||
*/
|
||||
preempt_disable();
|
||||
read_unlock(&tasklist_lock);
|
||||
preempt_enable_no_resched();
|
||||
cgroup_enter_frozen();
|
||||
preempt_enable_no_resched();
|
||||
freezable_schedule();
|
||||
cgroup_leave_frozen(true);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue