Re: [PATCH] pidfd: change do_notify_pidfd() to use __wake_up(poll_to_key(EPOLLIN))

From: Tycho Andersen
Date: Tue Feb 06 2024 - 12:03:49 EST


On Mon, Feb 05, 2024 at 03:13:48PM +0100, Oleg Nesterov wrote:
> rather than wake_up_all(). This way do_notify_pidfd() won't wakeup the
> POLLHUP-only waiters which wait for pid_task() == NULL.
>
> TODO:
> - as Christian pointed out, this asks for the new wake_up_all_poll()
> helper, it can already have other users.
>
> - we can probably discriminate the PIDFD_THREAD and non-PIDFD_THREAD
> waiters, but this needs more work. See
> https://lore.kernel.org/all/20240205140848.GA15853@xxxxxxxxxx/
>
> Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx>

Reviewed-by: Tycho Andersen <tandersen@xxxxxxxxxxx>