diff --git a/kernel/signal.c b/kernel/signal.c index bb2bf761f422..1c5140a75cee 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -2131,8 +2131,8 @@ static void ptrace_stop(int exit_code, int why, int clear_code, siginfo_t *info) */ preempt_disable(); read_unlock(&tasklist_lock); - preempt_enable_no_resched(); cgroup_enter_frozen(); + preempt_enable_no_resched(); freezable_schedule(); cgroup_leave_frozen(true); } else {