While reviewing io_req_local_work_add() I haven't found any real problems, but there are defintely rought edges. Remove one extra smp_mb__after_atomic(), add comments about how the synchronisation works, and improve mixing lazy with non-lazy work items. Pavel Begunkov (4): io_uring: adjust defer tw counting io_uring: clean up local tw add-wait sync io_uring: clean *local_work_add var naming io_uring: combine cq_wait_nr checks io_uring/io_uring.c | 58 ++++++++++++++++++++++++++++++++------------- 1 file changed, 42 insertions(+), 16 deletions(-) -- 2.43.0