aboutsummaryrefslogtreecommitdiffstats
path: root/io_uring
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2023-06-23 09:54:56 -0600
committerJens Axboe <axboe@kernel.dk>2023-07-17 10:05:48 -0600
commitad711c5d113f53d6f16096dd6ed9f4939a857149 (patch)
tree7e7debd8e97067fdd7dfa78b52f4817bcfdd32c9 /io_uring
parentfdf0eaf11452d72945af31804e2a1048ee1b574c (diff)
downloadlinux-ad711c5d113f53d6f16096dd6ed9f4939a857149.tar.gz
io_uring/poll: always set 'ctx' in io_cancel_data
This isn't strictly necessary for this callsite, as it uses it's internal lookup for this cancelation purpose. But let's be consistent with how it's used in general and set ctx as well. Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring')
-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 d4597efe14a7d..c7bb292c9046e 100644
--- a/io_uring/poll.c
+++ b/io_uring/poll.c
@@ -972,8 +972,8 @@ int io_poll_add(struct io_kiocb *req, unsigned int issue_flags)
int io_poll_remove(struct io_kiocb *req, unsigned int issue_flags)
{
struct io_poll_update *poll_update = io_kiocb_to_cmd(req, struct io_poll_update);
- struct io_cancel_data cd = { .data = poll_update->old_user_data, };
struct io_ring_ctx *ctx = req->ctx;
+ struct io_cancel_data cd = { .ctx = ctx, .data = poll_update->old_user_data, };
struct io_hash_bucket *bucket;
struct io_kiocb *preq;
int ret2, ret = 0;