Skip to content

Commit ab1dab9

Browse files
isilenceaxboe
authored andcommitted
io_uring: kill poll linking optimisation
With IORING_FEAT_FAST_POLL in place, io_put_req_find_next() for poll requests doesn't make much sense, and in any case re-adding it shouldn't be a problem considering batching in tctx_task_work(). We can remove it. Signed-off-by: Pavel Begunkov <[email protected]> Link: https://lore.kernel.org/r/15699682bf81610ec901d4e79d6da64baa9f70be.1639605189.git.asml.silence@gmail.com Signed-off-by: Jens Axboe <[email protected]>
1 parent 5641897 commit ab1dab9

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

fs/io_uring.c

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5485,7 +5485,6 @@ static bool __io_poll_complete(struct io_kiocb *req, __poll_t mask)
54855485
static void io_poll_task_func(struct io_kiocb *req, bool *locked)
54865486
{
54875487
struct io_ring_ctx *ctx = req->ctx;
5488-
struct io_kiocb *nxt;
54895488

54905489
if (io_poll_rewait(req, &req->poll)) {
54915490
spin_unlock(&ctx->completion_lock);
@@ -5509,11 +5508,8 @@ static void io_poll_task_func(struct io_kiocb *req, bool *locked)
55095508
spin_unlock(&ctx->completion_lock);
55105509
io_cqring_ev_posted(ctx);
55115510

5512-
if (done) {
5513-
nxt = io_put_req_find_next(req);
5514-
if (nxt)
5515-
io_req_task_submit(nxt, locked);
5516-
}
5511+
if (done)
5512+
io_put_req(req);
55175513
}
55185514
}
55195515

0 commit comments

Comments
 (0)