Skip to content

Commit 9d2ad29

Browse files
isilenceaxboe
authored andcommitted
io_uring: fix wrong arm_poll error handling
Leaving ip.error set when a request was punted to task_work execution is problematic, don't forget to clear it. Fixes: aa43477 ("io_uring: poll rework") Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/a6c84ef4182c6962380aebe11b35bdcb25b0ccfb.1655852245.git.asml.silence@gmail.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent c487a5a commit 9d2ad29

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fs/io_uring.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7145,6 +7145,7 @@ static int __io_arm_poll_handler(struct io_kiocb *req,
71457145
if (unlikely(ipt->error || !ipt->nr_entries)) {
71467146
poll->events |= EPOLLONESHOT;
71477147
req->apoll_events |= EPOLLONESHOT;
7148+
ipt->error = 0;
71487149
}
71497150
__io_poll_execute(req, mask, poll->events);
71507151
return 0;

0 commit comments

Comments
 (0)