Skip to content
Commit c729ed6f authored by David Howells's avatar David Howells Committed by Jakub Kicinski
Browse files

net: Use sendmsg(MSG_SPLICE_PAGES) not sendpage in skb_send_sock()



Use sendmsg() with MSG_SPLICE_PAGES rather than sendpage in
skb_send_sock().  This causes pages to be spliced from the source iterator
if possible.

This allows ->sendpage() to be replaced by something that can handle
multiple multipage folios in a single transaction.

Note that this could perhaps be improved to fill out a bvec array with all
the frags and then make a single sendmsg call, possibly sticking the header
on the front also.

Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
cc: Jens Axboe <axboe@kernel.dk>
cc: Matthew Wilcox <willy@infradead.org>
Link: https://lore.kernel.org/r/20230623225513.27322563

-3-dhowells@redhat.com
Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent f8dd95b2
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment