diff options
author | Dylan Yudaken <dylany@meta.com> | 2022-11-24 10:35:53 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2022-11-25 14:10:04 +0100 |
commit | 973fc83f3a94bdffcacf482641db38f57c7c8609 (patch) | |
tree | 8c186021f141d1325b128c354166f441578e4d63 /io_uring/poll.c | |
parent | io_uring: always lock in io_apoll_task_func (diff) | |
download | linux-973fc83f3a94bdffcacf482641db38f57c7c8609.tar.xz linux-973fc83f3a94bdffcacf482641db38f57c7c8609.zip |
io_uring: defer all io_req_complete_failed
All failures happen under lock now, and can be deferred. To be consistent
when the failure has happened after some multishot cqe has been
deferred (and keep ordering), always defer failures.
To make this obvious at the caller (and to help prevent a future bug)
rename io_req_complete_failed to io_req_defer_failed.
Signed-off-by: Dylan Yudaken <dylany@meta.com>
Link: https://lore.kernel.org/r/20221124093559.3780686-4-dylany@meta.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring/poll.c')
-rw-r--r-- | io_uring/poll.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/io_uring/poll.c b/io_uring/poll.c index 42aa10b50f6c..4bd43e6f5b72 100644 --- a/io_uring/poll.c +++ b/io_uring/poll.c @@ -317,7 +317,7 @@ static void io_apoll_task_func(struct io_kiocb *req, bool *locked) else if (ret == IOU_POLL_DONE) io_req_task_submit(req, locked); else - io_req_complete_failed(req, ret); + io_req_defer_failed(req, ret); } static void __io_poll_execute(struct io_kiocb *req, int mask) |