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.

io_uring/net: avoid import_ubuf for regvec send

With registered buffers we set up iterators in helpers like
io_import_fixed(), and there is no need for a import_ubuf() before that.
It was fine as we used real pointers for offset calculation, but that's
not the case anymore since introduction of ublk kernel buffers.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/9b2de1a50844f848f62c8de609b494971033a6b9.1743437358.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Pavel Begunkov and committed by
Jens Axboe
81ed1801 a1fbe0a1

+2
+2
io_uring/net.c
··· 359 359 kmsg->msg.msg_name = &kmsg->addr; 360 360 kmsg->msg.msg_namelen = addr_len; 361 361 } 362 + if (sr->flags & IORING_RECVSEND_FIXED_BUF) 363 + return 0; 362 364 if (!io_do_buffer_select(req)) { 363 365 ret = import_ubuf(ITER_SOURCE, sr->buf, sr->len, 364 366 &kmsg->msg.msg_iter);