Re: zero-copy between interfaces

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jan 13, 2020 at 6:09 PM Toke Høiland-Jørgensen <toke@xxxxxxxxxx> wrote:
>
> Ryan Goodfellow <rgoodfel@xxxxxxx> writes:
>
> > On Mon, Jan 13, 2020 at 11:43:02AM +0100, Toke Høiland-Jørgensen wrote:
> >>> Magnus Karlsson <magnus.karlsson@xxxxxxxxx> writes:
> >>>> On Mon, Jan 13, 2020 at 1:28 AM Ryan Goodfellow <rgoodfel@xxxxxxx> wrote:
> >>>>  The reason for wanting large memory maps is that our use case for XDP is network
> >>>>  emulation - and sometimes that means introducing delay factors that can require
> >>>>  a rather large in-memory packet buffers.
> >>>>
> >>>>  If there is interest in including this program in the official BPF samples I'm happy to
> >>>>  submit a patch. Any comments on the program are also much appreciated.
> >>>
> >>>  More examples are always useful, but the question is if it should
> >>>  reside in samples or outside the kernel in some other repo? Is there
> >>>  some good place in xdp-project github that could be used for this
> >>>  purpose?
> >>
> >> We could certainly create something; either a new xdp-samples
> >> repository, or an example-programs/ subdir of the xdp-tutorial? Which of
> >> those makes the most sense depends on the size of the program I think...
> >>
> >> -Toke
> >>
> >
> > I'm happy to provide patches or pull-requests in either case. The userspace
> > program is 1 file with 555 lines and the BPF program is 28 lines. I've
> > tested the userspace program with the 5.5 kernel. The BPF program requires
> > clang-9 to work properly (due to BTF features IIRC).
> >
> > - https://gitlab.com/mergetb/tech/network-emulation/kernel/blob/v5.5-moa/samples/bpf/xdpsock_multidev.c
> > - https://gitlab.com/mergetb/tech/network-emulation/kernel/blob/v5.5-moa/samples/bpf/xdpsock_multidev_kern.c
> >
> > The primary usefulness of this program relative to what's out there is
> > that it pushes packets between interfaces using a common memory map.
>
> Hmm, yeah, this could live in either samples or as standalone. IDK,
> Magnus what do you think?

Let us try the kernel samples first. Then and if the folks on the
mailing list do not want more samples in there, we fall back on the
xdp-tutorial repo.

/Magnus

> -Toke
>




[Index of Archives]     [Linux Networking Development]     [Fedora Linux Users]     [Linux SCTP]     [DCCP]     [Gimp]     [Yosemite Campsites]

  Powered by Linux