io_uring: inline __io_req_complete_post()
authorPavel Begunkov <asml.silence@gmail.com>
Thu, 17 Nov 2022 18:41:06 +0000 (18:41 +0000)
committerJens Axboe <axboe@kernel.dk>
Mon, 21 Nov 2022 14:45:19 +0000 (07:45 -0700)
There is only one user of __io_req_complete_post(), inline it.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/ef4c9059950a3da5cf68df00f977f1fd13bd9306.1668597569.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c
io_uring/io_uring.h

index 9925ac08c39856667db9b85f04376176febabad6..1299f9c8567aeeac884db67c9bf0e904d275b81f 100644 (file)
@@ -854,19 +854,14 @@ static void __io_req_complete_put(struct io_kiocb *req)
        }
 }
 
-void __io_req_complete_post(struct io_kiocb *req)
-{
-       if (!(req->flags & REQ_F_CQE_SKIP))
-               __io_fill_cqe_req(req->ctx, req);
-       __io_req_complete_put(req);
-}
-
 void io_req_complete_post(struct io_kiocb *req)
 {
        struct io_ring_ctx *ctx = req->ctx;
 
        io_cq_lock(ctx);
-       __io_req_complete_post(req);
+       if (!(req->flags & REQ_F_CQE_SKIP))
+               __io_fill_cqe_req(ctx, req);
+       __io_req_complete_put(req);
        io_cq_unlock_post(ctx);
 }
 
index 38d9e149d2db77ad99938bfa57ce526f2b43801e..69fbd27c7577b9b0501a57ffa82ae393f9cf5af2 100644 (file)
@@ -32,7 +32,6 @@ int io_run_local_work(struct io_ring_ctx *ctx);
 void io_req_complete_failed(struct io_kiocb *req, s32 res);
 void __io_req_complete(struct io_kiocb *req, unsigned issue_flags);
 void io_req_complete_post(struct io_kiocb *req);
-void __io_req_complete_post(struct io_kiocb *req);
 bool io_post_aux_cqe(struct io_ring_ctx *ctx, u64 user_data, s32 res, u32 cflags,
                     bool allow_overflow);
 bool io_fill_cqe_aux(struct io_ring_ctx *ctx, u64 user_data, s32 res, u32 cflags,