]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: thin down io_commit_cqring()
authorPavel Begunkov <asml.silence@gmail.com>
Thu, 17 Mar 2022 02:03:41 +0000 (02:03 +0000)
committerJens Axboe <axboe@kernel.dk>
Thu, 17 Mar 2022 02:26:32 +0000 (20:26 -0600)
commit91b263e17948f24f7966382d210ccf73c57ecc07
tree49d6f590d4f9d77b8090ce944ac440e53dfc578c
parentb52d27d0998df21bfa6f8c335e12f67e7abb1385
io_uring: thin down io_commit_cqring()

io_commit_cqring() is currently always under spinlock section, so it's
always better to keep it as slim as possible. Move
__io_commit_cqring_flush() out of it into ev_posted*(). If fast checks
do fail and this post-processing is required, we'll reacquire
->completion_lock, which is fine as we don't care about performance of
draining and offset timeouts.

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