io_uring: clean up io_queue_next()
authorPavel Begunkov <asml.silence@gmail.com>
Mon, 21 Mar 2022 22:02:24 +0000 (22:02 +0000)
committerJens Axboe <axboe@kernel.dk>
Sun, 17 Apr 2022 22:51:24 +0000 (16:51 -0600)
commit1974d4772e9397d4374f1c85be82057136db9912
tree766efd9080e91206da8554d0b0138784b659ebc5
parent878355dbef6ba86aaab3a9c1879d76139d25f322
io_uring: clean up io_queue_next()

Move fast check out of io_queue_next(), it makes req->flags checks in
__io_submit_flush_completions() a bit clearer and grants us better
comtrol, e.g. can remove now not justified unlikely() in
__io_submit_flush_completions(). Also, we don't care about having this
check in io_free_req() as the function is a slow path and
io_req_find_next() handles it correctly.

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