io_uring: optimise iowq refcounting
authorPavel Begunkov <asml.silence@gmail.com>
Sun, 15 Aug 2021 09:40:18 +0000 (10:40 +0100)
committerJens Axboe <axboe@kernel.dk>
Mon, 23 Aug 2021 19:10:37 +0000 (13:10 -0600)
commit48dcd38d73c22b22bf9dc1c01b0ca0b8414b31da
tree03f30a7dfe5404cf3844eaf7afe1a3a8a18fc9da
parenta141dd896f544df9627502cfb3fc1a73fb6587e4
io_uring: optimise iowq refcounting

If a requests is forwarded into io-wq, there is a good chance it hasn't
been refcounted yet and we can save one req_ref_get() by setting the
refcount number to the right value directly.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/2d53f4449faaf73b4a4c5de667fc3c176d974860.1628981736.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c