mirror of
https://github.com/torvalds/linux
synced 2024-09-06 01:40:28 +00:00
io_uring: poll: remove unnecessary req->ref set
We now don't need to set req->refcount for poll requests since the reworked poll code ensures no request release race. Signed-off-by: Hao Xu <howeyxu@tencent.com> Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/ec6fee45705890bdb968b0c175519242753c0215.1655371007.git.asml.silence@gmail.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
53ccf69bda
commit
3654ab0c51
|
@ -689,7 +689,6 @@ int io_poll_add_prep(struct io_kiocb *req, const struct io_uring_sqe *sqe)
|
||||||
if ((flags & IORING_POLL_ADD_MULTI) && (req->flags & REQ_F_CQE_SKIP))
|
if ((flags & IORING_POLL_ADD_MULTI) && (req->flags & REQ_F_CQE_SKIP))
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
io_req_set_refcount(req);
|
|
||||||
poll->events = io_poll_parse_events(sqe, flags);
|
poll->events = io_poll_parse_events(sqe, flags);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue