[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2840ec03-1d2b-f9c8-f215-61430f758925@gmail.com>
Date: Mon, 4 Jul 2022 14:31:13 +0100
From: Pavel Begunkov <asml.silence@...il.com>
To: David Ahern <dsahern@...nel.org>
Cc: io-uring@...r.kernel.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org,
"David S . Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Jonathan Lemon <jonathan.lemon@...il.com>,
Willem de Bruijn <willemb@...gle.com>,
Jens Axboe <axboe@...nel.dk>, kernel-team@...com
Subject: Re: [RFC net-next v3 05/29] net: bvec specific path in
zerocopy_sg_from_iter
On 6/28/22 23:52, David Ahern wrote:
> On Tue, Jun 28, 2022 at 07:56:27PM +0100, Pavel Begunkov wrote:
>> Add an bvec specialised and optimised path in zerocopy_sg_from_iter.
>> It'll be used later for {get,put}_page() optimisations.
>>
>> Signed-off-by: Pavel Begunkov <asml.silence@...il.com>
>> ---
>> net/core/datagram.c | 47 +++++++++++++++++++++++++++++++++++++++++++++
>> 1 file changed, 47 insertions(+)
>>
>
> Rather than propagating iter functions, I have been using the attached
> patch for a few months now. It leverages your ubuf_info in msghdr to
> allow in kernel users to pass in their own iter handler.
If the series is going to be picked up for 5.20, how about we delay
this one for 5.21? I'll have time to think about it (maybe moving
the skb managed flag setup inside?), and will anyway need to send
some omitted patches then.
I was also entertaining the idea of having a smaller ubuf_info to
fit it into io_kiocb, which is tight on space.
struct ubuf_info {
void *callback;
refcount_t refcnt;
u32 flags;
};
struct ubuf_info_msgzerocopy {
struct ubuf_info ubuf;
/* others fields */
};
48 bytes would be taking too much, but 16 looks nice. It might
make sense to move the callback into struct msghdr, I don't know.
--
Pavel Begunkov
Powered by blists - more mailing lists