]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: enable req cache for task_work items
authorJens Axboe <axboe@kernel.dk>
Wed, 10 Feb 2021 00:03:21 +0000 (00:03 +0000)
committerJens Axboe <axboe@kernel.dk>
Wed, 10 Feb 2021 14:28:43 +0000 (07:28 -0700)
commit1a12bfc276c96f6b8bccdde2e07b0c9e1e504a00
tree389d3828515b115544d7129a685284a46727d885
parentdbe6541525848a1b8d01916f663dc94cf053763c
io_uring: enable req cache for task_work items

task_work is run without utilizing the req alloc cache, so any deferred
items don't get to take advantage of either the alloc or free side of it.
With task_work now being wrapped by io_uring, we can use the ctx
completion state to both use the req cache and the completion flush
batching.

With this, the only request type that cannot take advantage of the req
cache is IRQ driven IO for regular files / block devices. Anything else,
including IOPOLL polled IO to those same tyes, will take advantage of it.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c