Re: [PATCH] io_uring/io-wq: don't call try_to_wake_up() twice in io_wq_worker_wake()
From: Christian Brauner
Date: Mon Oct 12 2026 - 04:43:20 EST
On Sun, Oct 11, 2026 at 05:13:16PM +0200, Oleg Nesterov wrote:
> io_wq_worker_wake() does an unconditional wake_up_process(). This means
> that __set_notify_signal() makes no real sense. Change it to use
> set_tsk_thread_flag(TIF_NOTIFY_SIGNAL) instead to avoid test_and_set_bit()
> and another wake_up_state(TASK_INTERRUPTIBLE) if NOTIFY_SIGNAL was not set.
>
> Perhaps io_wq_worker_wake() can rely on __set_notify_signal() solely, but I
> don't understand this code enough and this patch doesn't change the current
> behaviour.
>
> Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx>
> ---
Reviewed-by: Christian Brauner (Amutable) <brauner@xxxxxxxxxx>