Re: [syzbot] [kernel?] inconsistent lock state in ptrace_attach

From: Oleg Nesterov
Date: Fri Nov 17 2023 - 07:33:39 EST


On 11/17, Peter Zijlstra wrote:
>
> --- a/kernel/ptrace.c
> +++ b/kernel/ptrace.c
> @@ -461,7 +461,7 @@ static int ptrace_attach(struct task_str
> return retval;
> }
>
> - scoped_guard (write_lock, &tasklist_lock) {
> + scoped_guard (write_lock_irq, &tasklist_lock) {

FWIW,

Acked-by: Oleg Nesterov <oleg@xxxxxxxxxx>