From: Pavel Begunkov <[email protected]>
To: Jens Axboe <[email protected]>, [email protected]
Subject: [PATCH 1/7] io_uring: move io_fallback_req_func()
Date: Mon, 9 Aug 2021 20:18:07 +0100 [thread overview]
Message-ID: <d0a8f9d9a0057ed761d6237167d51c9378798d2d.1628536684.git.asml.silence@gmail.com> (raw)
In-Reply-To: <[email protected]>
Move io_fallback_req_func() to kill yet another forward declaration.
Signed-off-by: Pavel Begunkov <[email protected]>
---
fs/io_uring.c | 24 +++++++++++-------------
1 file changed, 11 insertions(+), 13 deletions(-)
diff --git a/fs/io_uring.c b/fs/io_uring.c
index 21dccfc8665f..889e11892227 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -1066,8 +1066,6 @@ static void io_submit_flush_completions(struct io_ring_ctx *ctx);
static bool io_poll_remove_waitqs(struct io_kiocb *req);
static int io_req_prep_async(struct io_kiocb *req);
-static void io_fallback_req_func(struct work_struct *unused);
-
static struct kmem_cache *req_cachep;
static const struct file_operations io_uring_fops;
@@ -1144,6 +1142,17 @@ static inline bool io_is_timeout_noseq(struct io_kiocb *req)
return !req->timeout.off;
}
+static void io_fallback_req_func(struct work_struct *work)
+{
+ struct io_ring_ctx *ctx = container_of(work, struct io_ring_ctx,
+ fallback_work.work);
+ struct llist_node *node = llist_del_all(&ctx->fallback_llist);
+ struct io_kiocb *req, *tmp;
+
+ llist_for_each_entry_safe(req, tmp, node, io_task_work.fallback_node)
+ req->io_task_work.func(req);
+}
+
static struct io_ring_ctx *io_ring_ctx_alloc(struct io_uring_params *p)
{
struct io_ring_ctx *ctx;
@@ -2465,17 +2474,6 @@ static bool io_rw_should_reissue(struct io_kiocb *req)
}
#endif
-static void io_fallback_req_func(struct work_struct *work)
-{
- struct io_ring_ctx *ctx = container_of(work, struct io_ring_ctx,
- fallback_work.work);
- struct llist_node *node = llist_del_all(&ctx->fallback_llist);
- struct io_kiocb *req, *tmp;
-
- llist_for_each_entry_safe(req, tmp, node, io_task_work.fallback_node)
- req->io_task_work.func(req);
-}
-
static void __io_complete_rw(struct io_kiocb *req, long res, long res2,
unsigned int issue_flags)
{
--
2.32.0
next prev parent reply other threads:[~2021-08-09 19:18 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-09 19:18 [PATCH 0/7] the rest of for-next patches Pavel Begunkov
2021-08-09 19:18 ` Pavel Begunkov [this message]
2021-08-09 19:18 ` [PATCH 2/7] io_uring: cache __io_free_req()'d requests Pavel Begunkov
2021-08-09 19:18 ` [PATCH 3/7] io_uring: remove redundant args from cache_free Pavel Begunkov
2021-08-09 19:18 ` [PATCH 4/7] io_uring: use inflight_entry instead of compl.list Pavel Begunkov
2021-08-09 19:18 ` [PATCH 5/7] io_uring: inline struct io_comp_state Pavel Begunkov
2021-08-09 19:18 ` [PATCH 6/7] io_uring: remove extra argument for overflow flush Pavel Begunkov
2021-08-09 19:18 ` [PATCH 7/7] io_uring: inline io_poll_remove_waitqs Pavel Begunkov
2021-08-09 19:47 ` [PATCH 0/7] the rest of for-next patches 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=d0a8f9d9a0057ed761d6237167d51c9378798d2d.1628536684.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