Re: [PATCH 8/9] ptrace: Use siglock instead of tasklist_lock in ptrace_check_attach

From: Oleg Nesterov
Date: Wed Apr 27 2022 - 11:20:38 EST


On 04/26, Eric W. Biederman wrote:
>
> + if (lock_task_sighand(child, &flags)) {
> + if (child->ptrace && child->parent == current) {
> + WARN_ON(READ_ONCE(child->__state) == __TASK_TRACED);
> + /*
> + * child->sighand can't be NULL, release_task()
> + * does ptrace_unlink() before __exit_signal().
> + */
> + if (ignore_state || ptrace_freeze_traced(child))
> + ret = 0;

The comment above is no longer relevant, it should be removed.

Oleg.