io_uring: make __tctx_task_work_run() take an io_wq_work_list
authorJens Axboe <axboe@kernel.dk>
Fri, 22 Nov 2024 16:08:06 +0000 (09:08 -0700)
committerJens Axboe <axboe@kernel.dk>
Fri, 22 Nov 2024 18:05:09 +0000 (11:05 -0700)
commite3a0c90b3e357cd6bb92d7747b80cad3e21b2510
treea8616a0b9af2a0609443068a578cd4a7d64bfb15
parent9b1a5a4e4e24154c326e4f008f61f698f747fc8a
io_uring: make __tctx_task_work_run() take an io_wq_work_list

The normal task_work logic doesn't really need it, as it always runs
all of the pending work. But for SQPOLL, it can now pass in its
retry_list which simplifies the tracking of split up task_work running.

This avoids passing io_wq_work_node around. Rather than pass in a list,
SQPOLL could re-add the leftover items to the generic task_work list.
But that requires re-locking the task_lock and using task_list for that,
whereas having a separate retry list allows for skipping those steps.
The downside is that now two lists need checking, but that's now it
was before as well.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c
io_uring/io_uring.h
io_uring/sqpoll.c