]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix skipping disabling sqo on exec
authorPavel Begunkov <asml.silence@gmail.com>
Sun, 17 Jan 2021 02:29:56 +0000 (02:29 +0000)
committerJens Axboe <axboe@kernel.dk>
Sun, 17 Jan 2021 04:02:49 +0000 (21:02 -0700)
commit8b70722d995030406b1c2d4301b1e746952c1248
tree02e6b465ed07e8fd9bd5b3c8bb9794f90be39422
parent649efc551313fbbe28b49a7872e696e434b676ca
io_uring: fix skipping disabling sqo on exec

If there are no requests at the time __io_uring_task_cancel() is called,
tctx_inflight() returns zero and and it terminates not getting a chance
to go through __io_uring_files_cancel() and do
io_disable_sqo_submit(). And we absolutely want them disabled by the
time cancellation ends.

Reported-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Fixes: 0ffe099d6d55 ("io_uring: stop SQPOLL submit on creator's death")
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c