Re: [PATCH] io_uring: restore RCU read section in io_req_local_work_add()

Jens Axboe <[email protected]> Thu, 9 Jul 2026 11:46:00 -0600
Newsgroups org.kernel.vger.io-uring
Message-ID <[email protected]>
On 7/9/26 11:44 AM, Jens Axboe wrote:
> 
> On Thu, 09 Jul 2026 10:51:00 +0700, Woraphat Khiaodaeng wrote:
>> The task-work refactor that moved io_req_local_work_add() out of
>> io_uring.c into the new io_uring/tw.c dropped the whole-body guard(rcu)()
>> that used to cover the function body.
>>
>> For DEFER_TASKRUN rings the ring teardown still relies on that RCU read
>> section pairing with its grace period:
>>
>> [...]
> 
> Applied, thanks!
> 
> [1/1] io_uring: restore RCU read section in io_req_local_work_add()
>       commit: 648790e0952789527ec68548edbedbc0fcff43b5

Side note: with your patch applied, we can also do:

https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux.git/commit/?h=io_uring-7.2&id=f3176c8ac4217c88fe1147ab084c47092921ffc4

as io_ctx_mark_taskrun() is no longer called outside the RCU read side
lock anymore. So I did that on top.

-- 
Jens Axboe