summaryrefslogtreecommitdiff
path: root/io_uring/poll.c
diff options
context:
space:
mode:
authorPavel Begunkov <asml.silence@gmail.com>2022-11-23 11:33:41 +0000
committerJens Axboe <axboe@kernel.dk>2022-11-23 10:45:31 -0700
commit1bec951c3809051f64a6957fe86d1b4786cc0313 (patch)
tree7964364c1c55aea528254617dc80a3c6e6fd14ad /io_uring/poll.c
parentfa18fa2272c7469e470dcb7bf838ea50a25494ca (diff)
io_uring: iopoll protect complete_post
io_req_complete_post() may be used by iopoll enabled rings, grab locks in this case. That requires to pass issue_flags to propagate the locking state. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/cc6d854065c57c838ca8e8806f707a226b70fd2d.1669203009.git.asml.silence@gmail.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring/poll.c')
-rw-r--r--io_uring/poll.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io_uring/poll.c b/io_uring/poll.c
index cd4d98d622d2..4624e5eba63e 100644
--- a/io_uring/poll.c
+++ b/io_uring/poll.c
@@ -312,7 +312,7 @@ static void io_apoll_task_func(struct io_kiocb *req, bool *locked)
io_poll_tw_hash_eject(req, locked);
if (ret == IOU_POLL_REMOVE_POLL_USE_RES)
- io_req_complete_post(req);
+ io_req_complete_post_tw(req, locked);
else if (ret == IOU_POLL_DONE)
io_req_task_submit(req, locked);
else