io_uring: introduce struct iou_vec

I need a convenient way to pass around and work with iovec+size pair,
put them into a structure and makes use of it in rw.c

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/d39fadafc9e9047b0a292e5be6db3cf2f48bb1f7.1741362889.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
Pavel Begunkov
2025-03-07 16:00:29 +00:00
committed by Jens Axboe
parent 6e3da40ed6
commit e1d4995909
5 changed files with 39 additions and 12 deletions

View File

@@ -9,13 +9,13 @@ struct io_meta_state {
};
struct io_async_rw {
struct iou_vec vec;
size_t bytes_done;
struct iovec *free_iovec;
struct_group(clear,
struct iov_iter iter;
struct iov_iter_state iter_state;
struct iovec fast_iov;
int free_iov_nr;
/*
* wpq is for buffered io, while meta fields are used with
* direct io