Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

block: add for_each_mp_bvec()

Add helper of for_each_mp_bvec() for io_uring to import fixed kernel
buffer.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20250325135155.935398-3-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Ming Lei and committed by
Jens Axboe
149974fd 8622b20f

+6
+6
include/linux/bvec.h
··· 184 184 ((bvl = bvec_iter_bvec((bio_vec), (iter))), 1); \ 185 185 bvec_iter_advance_single((bio_vec), &(iter), (bvl).bv_len)) 186 186 187 + #define for_each_mp_bvec(bvl, bio_vec, iter, start) \ 188 + for (iter = (start); \ 189 + (iter).bi_size && \ 190 + ((bvl = mp_bvec_iter_bvec((bio_vec), (iter))), 1); \ 191 + bvec_iter_advance_single((bio_vec), &(iter), (bvl).bv_len)) 192 + 187 193 /* for iterating one bio from start to end */ 188 194 #define BVEC_ITER_ALL_INIT (struct bvec_iter) \ 189 195 { \