summaryrefslogtreecommitdiffstats
path: root/fs/io_uring.c
diff options
context:
space:
mode:
authorPavel Begunkov <asml.silence@gmail.com>2020-12-20 14:21:44 +0100
committerJens Axboe <axboe@kernel.dk>2020-12-20 19:05:39 +0100
commitf57555eda979ca085d2524db81e14b8a6089e15e (patch)
tree9263b1ae0949ff392bf515c42bff619b2b8fd503 /fs/io_uring.c
parentio_uring: always progress task_work on task cancel (diff)
downloadlinux-f57555eda979ca085d2524db81e14b8a6089e15e.tar.xz
linux-f57555eda979ca085d2524db81e14b8a6089e15e.zip
io_uring: end waiting before task cancel attempts
Get rid of TASK_UNINTERRUPTIBLE and waiting with finish_wait before going for next iteration in __io_uring_task_cancel(), because __io_uring_files_cancel() doesn't expect that sheduling is disallowed. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fs/io_uring.c')
-rw-r--r--fs/io_uring.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/io_uring.c b/fs/io_uring.c
index d0ab6b503a9f..fbf747803dbc 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -8989,9 +8989,9 @@ void __io_uring_task_cancel(void)
if (inflight != tctx_inflight(tctx))
continue;
schedule();
+ finish_wait(&tctx->wait, &wait);
} while (1);
- finish_wait(&tctx->wait, &wait);
atomic_dec(&tctx->in_idle);
}