diff options
author | Pavel Begunkov <asml.silence@gmail.com> | 2021-06-14 02:36:19 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-06-14 08:23:13 -0600 |
commit | 157d257f99c15c43668a98f804e3e3e6eb956464 (patch) | |
tree | 099e4e5fde374a72fc596d2fe86cae2dfc16c0d3 /fs/io_uring.c | |
parent | d878c81610e187becff1454f36b63c59ec165566 (diff) | |
download | lwn-157d257f99c15c43668a98f804e3e3e6eb956464.tar.gz lwn-157d257f99c15c43668a98f804e3e3e6eb956464.zip |
io_uring: remove rsrc put work irq save/restore
io_rsrc_put_work() is executed by workqueue in non-irq context, so no
need for irqsave/restore variants of spinlocking.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/2a7f77220735f4ad404ac885b4d73bdf42d2f836.1623634181.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fs/io_uring.c')
-rw-r--r-- | fs/io_uring.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/io_uring.c b/fs/io_uring.c index 6fda9fdee582..55e449d84b3e 100644 --- a/fs/io_uring.c +++ b/fs/io_uring.c @@ -7555,14 +7555,13 @@ static void __io_rsrc_put_work(struct io_rsrc_node *ref_node) if (prsrc->tag) { bool lock_ring = ctx->flags & IORING_SETUP_IOPOLL; - unsigned long flags; io_ring_submit_lock(ctx, lock_ring); - spin_lock_irqsave(&ctx->completion_lock, flags); + spin_lock_irq(&ctx->completion_lock); io_cqring_fill_event(ctx, prsrc->tag, 0, 0); ctx->cq_extra++; io_commit_cqring(ctx); - spin_unlock_irqrestore(&ctx->completion_lock, flags); + spin_unlock_irq(&ctx->completion_lock); io_cqring_ev_posted(ctx); io_ring_submit_unlock(ctx, lock_ring); } |