aboutsummaryrefslogtreecommitdiffstats
path: root/io_uring/kbuf.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2024-03-07 12:53:24 -0700
committerJens Axboe <axboe@kernel.dk>2024-03-08 07:56:27 -0700
commit186daf2385295acf19ecf48f4d5214cc2d925933 (patch)
treeb630fe6f56ce7e0d86497a5e78388f50d7609cb4 /io_uring/kbuf.c
parent9817ad85899fb695f875610fb743cb18cf087582 (diff)
downloadlinux-186daf2385295acf19ecf48f4d5214cc2d925933.tar.gz
io_uring/kbuf: rename REQ_F_PARTIAL_IO to REQ_F_BL_NO_RECYCLE
We only use the flag for this purpose, so rename it accordingly. This further prevents various other use cases of it, keeping it clean and consistent. Then we can also check it in one spot, when it's being attempted recycled, and remove some dead code in io_kbuf_recycle_ring(). Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring/kbuf.c')
-rw-r--r--io_uring/kbuf.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/io_uring/kbuf.c b/io_uring/kbuf.c
index 3d257ed9031b0..9be42bff936b9 100644
--- a/io_uring/kbuf.c
+++ b/io_uring/kbuf.c
@@ -81,15 +81,6 @@ bool io_kbuf_recycle_legacy(struct io_kiocb *req, unsigned issue_flags)
struct io_buffer_list *bl;
struct io_buffer *buf;
- /*
- * For legacy provided buffer mode, don't recycle if we already did
- * IO to this buffer. For ring-mapped provided buffer mode, we should
- * increment ring->head to explicitly monopolize the buffer to avoid
- * multiple use.
- */
- if (req->flags & REQ_F_PARTIAL_IO)
- return false;
-
io_ring_submit_lock(ctx, issue_flags);
buf = req->kbuf;