From: Pavel Begunkov <[email protected]>
To: Jens Axboe <[email protected]>, [email protected]
Subject: [PATCH 1/3] io_uring: fix drain with rsrc CQEs
Date: Tue, 27 Apr 2021 16:13:51 +0100 [thread overview]
Message-ID: <2b32f5f0a40d5928c3466d028f936e167f0654be.1619536280.git.asml.silence@gmail.com> (raw)
In-Reply-To: <[email protected]>
Resource emitted CQEs are not bound to requests, so fix up counters used
for DRAIN/defer logic.
Fixes: b60c8dce33895 ("io_uring: preparation for rsrc tagging")
Signed-off-by: Pavel Begunkov <[email protected]>
---
fs/io_uring.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/fs/io_uring.c b/fs/io_uring.c
index 63ff70587d4f..d3b7fe6ccb0e 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -7536,6 +7536,7 @@ static void __io_rsrc_put_work(struct io_rsrc_node *ref_node)
io_ring_submit_lock(ctx, lock_ring);
spin_lock_irqsave(&ctx->completion_lock, flags);
io_cqring_fill_event(ctx, prsrc->tag, 0, 0);
+ ctx->cq_extra++;
io_commit_cqring(ctx);
spin_unlock_irqrestore(&ctx->completion_lock, flags);
io_cqring_ev_posted(ctx);
--
2.31.1
next prev parent reply other threads:[~2021-04-27 15:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-27 15:13 [PATCH 5.13 0/3] drain rsrc fix Pavel Begunkov
2021-04-27 15:13 ` Pavel Begunkov [this message]
2021-04-27 15:13 ` [PATCH 2/3] io_uring: dont overlap internal and user req flags Pavel Begunkov
2021-04-27 15:13 ` [PATCH 3/3] io_uring: add more build check for uapi Pavel Begunkov
2021-04-28 14:04 ` [PATCH 5.13 0/3] drain rsrc fix Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2b32f5f0a40d5928c3466d028f936e167f0654be.1619536280.git.asml.silence@gmail.com \
[email protected] \
[email protected] \
[email protected] \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox