summaryrefslogtreecommitdiff
path: root/io_uring
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2022-09-24 18:27:08 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2022-09-24 18:27:08 +0300
commit3db61221f4e8f18d1dd6e45dbe9e3702ff2d67ab (patch)
tree90258cea62d0a187b4a20badf60d34045b53d13e /io_uring
parent0be27f7be2e5def5577de097fb420af09acf0983 (diff)
parente775f93f2ab976a2cdb4a7b53063cbe890904f73 (diff)
downloadlinux-3db61221f4e8f18d1dd6e45dbe9e3702ff2d67ab.tar.xz
Merge tag 'io_uring-6.0-2022-09-23' of git://git.kernel.dk/linux
Pull io_uring fix from Jens Axboe: "Just a single fix for an issue with un-reaped IOPOLL requests on ring exit" * tag 'io_uring-6.0-2022-09-23' of git://git.kernel.dk/linux: io_uring: ensure that cached task references are always put on exit
Diffstat (limited to 'io_uring')
-rw-r--r--io_uring/io_uring.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/io_uring/io_uring.c b/io_uring/io_uring.c
index b9640ad5069f..2965b354efc8 100644
--- a/io_uring/io_uring.c
+++ b/io_uring/io_uring.c
@@ -2648,6 +2648,9 @@ static __cold void io_ring_ctx_wait_and_kill(struct io_ring_ctx *ctx)
io_kill_timeouts(ctx, NULL, true);
/* if we failed setting up the ctx, we might not have any rings */
io_iopoll_try_reap_events(ctx);
+ /* drop cached put refs after potentially doing completions */
+ if (current->io_uring)
+ io_uring_drop_tctx_refs(current);
}
INIT_WORK(&ctx->exit_work, io_ring_exit_work);