lkml.org 
[lkml]   [2023]   [Jun]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH net-next v3 01/18] net: Copy slab data for sendmsg(MSG_SPLICE_PAGES)
    Date
    Jakub Kicinski <kuba@kernel.org> wrote:

    > If we can't reach instant agreement --
    > can you strategically separate out the minimal set of changes required
    > to just kill MSG_SENDPAGE_NOTLAST. IMHO it's worth getting that into
    > 6.5.

    Paolo Abeni <pabeni@redhat.com> wrote:

    > Given all the above, and the late stage of the current devel cycle,
    > would you consider slicing down this series to just kill
    > MSG_SENDPAGE_NOTLAST, as Jakub suggested?

    I could do that.

    There is also another alternative. I could just push the sendpage wrappers up
    the stack into the higher-level callers. Basically this:

    int udp_sendpage(struct sock *sk, struct page *page, int offset,
    size_t size, int flags)
    {
    struct bio_vec bvec;
    struct msghdr msg = { .msg_flags = flags | MSG_SPLICE_PAGES };

    if (flags & MSG_SENDPAGE_NOTLAST)
    msg.msg_flags |= MSG_MORE;

    bvec_set_page(&bvec, page, size, offset);
    iov_iter_bvec(&msg.msg_iter, ITER_SOURCE, &bvec, 1, size);
    return udp_sendmsg(sk, &msg, size);
    }

    and kill off sendpage and MSG_SENDPAGE_NOTLAST.

    David

    \
     
     \ /
      Last update: 2023-06-23 11:09    [W:9.728 / U:0.244 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site