io_uring: support true async buffered reads, if file provides it async-buffered.7
authorJens Axboe <axboe@kernel.dk>
Fri, 22 May 2020 15:24:42 +0000 (09:24 -0600)
committerJens Axboe <axboe@kernel.dk>
Thu, 18 Jun 2020 14:40:50 +0000 (08:40 -0600)
commite3af66e01cc6477f0f28c581e1cc44d0e5279775
tree9bff8738a1b8a1de703e1ec4f01320ea2362fd97
parent3617531b89f4500086a50d7158f9136d86a26012
io_uring: support true async buffered reads, if file provides it

If the file is flagged with FMODE_BUF_RASYNC, then we don't have to punt
the buffered read to an io-wq worker. Instead we can rely on page
unlocking callbacks to support retry based async IO. This is a lot more
efficient than doing async thread offload.

The retry is done similarly to how we handle poll based retry. From
the unlock callback, we simply queue the retry to a task_work based
handler.

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