io_uring: recycle provided buffer if we punt to io-wq
io_arm_poll_handler() will recycle the buffer appropriately if we end up arming poll (or if we're ready to retry), but not for the io-wq case if we have attempted poll first. Explicitly recycle the buffer to avoid both hanging on to it too long, but also to avoid multiple reads grabbing the same one. This can happen for ring mapped buffers, since it hasn't necessarily been committed. Fixes: c7fb1942 ("io_uring: add support for ring mapped supplied buffers") Link: https://github.com/axboe/liburing/issues/605Signed-off-by: Jens Axboe <axboe@kernel.dk>
Showing
Please register or sign in to comment