Messages in this thread | | | Date | Wed, 13 Apr 2022 15:29:22 +0200 | From | Oleg Nesterov <> | Subject | Re: [PATCH 1/5] sched,signal,ptrace: Rework TASK_TRACED, TASK_STOPPED state |
| |
On 04/12, Peter Zijlstra wrote: > > @@ -475,8 +483,10 @@ static int ptrace_attach(struct task_str > * in and out of STOPPED are protected by siglock. > */ > if (task_is_stopped(task) && > - task_set_jobctl_pending(task, JOBCTL_TRAP_STOP | JOBCTL_TRAPPING)) > + task_set_jobctl_pending(task, JOBCTL_TRAP_STOP | JOBCTL_TRAPPING)) { > + task->jobctl &= ~JOBCTL_STOPPED; > signal_wake_up_state(task, __TASK_STOPPED);
OK, but just for record before I forget...
It seems that we can s/JOBCTL_STOPPED/JOBCTL_TRACED/ instead, and kill the nasty wait_on_bit(JOBCTL_TRAPPING_BIT) along with JOBCTL_TRAPPING_BIT. Sure, this doesn't belong to this series.
Oleg.
| |