Skip to content

Commit

Permalink
io_uring: signal SQPOLL task_work with TWA_SIGNAL_NO_IPI
Browse files Browse the repository at this point in the history
Before SQPOLL was transitioned to managing its own task_work, the core
used TWA_SIGNAL_NO_IPI to ensure that task_work was processed. If not,
we can't be sure that all task_work is processed at SQPOLL thread exit
time.

Fixes: af5d68f ("io_uring/sqpoll: manage task_work privately")
Cc: [email protected]
Signed-off-by: Jens Axboe <[email protected]>
  • Loading branch information
axboe committed Jun 25, 2024
1 parent 26b9766 commit dbcabac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions io_uring/io_uring.c
Original file line number Diff line number Diff line change
Expand Up @@ -1259,8 +1259,8 @@ static void io_req_normal_work_add(struct io_kiocb *req)
if (ctx->flags & IORING_SETUP_SQPOLL) {
struct io_sq_data *sqd = ctx->sq_data;

if (wq_has_sleeper(&sqd->wait))
wake_up(&sqd->wait);
if (sqd->thread)
__set_notify_signal(sqd->thread);
return;
}

Expand Down

0 comments on commit dbcabac

Please sign in to comment.