[prev in list] [next in list] [prev in thread] [next in thread] 

List:       xdp-newbies
Subject:    RE: XDP multi-buffer and AF_XDP
From:       "Karlsson, Magnus" <magnus.karlsson () intel ! com>
Date:       2022-06-27 13:23:31
Message-ID: MW3PR11MB46027B4C9C79DFB6C0DE0564F7B99 () MW3PR11MB4602 ! namprd11 ! prod ! outlook ! com
[Download RAW message or body]



> -----Original Message-----
> From: Kal Cutter Conley <kal.conley@dectris.com>
> Sent: Monday, June 27, 2022 12:38 PM
> To: Sarkar, Tirthendu <tirthendu.sarkar@intel.com>
> Cc: Fijalkowski, Maciej <maciej.fijalkowski@intel.com>; Karlsson, Magnus
> <magnus.karlsson@intel.com>; eric@sage.org; Jesper Dangaard Brouer
> <jbrouer@redhat.com>; Toke Høiland-Jørgensen <toke@redhat.com>; Xdp
> <xdp-newbies@vger.kernel.org>
> Subject: Re: XDP multi-buffer and AF_XDP
> 
> Hi Tirtha,
> We are mainly working with mlx5 NICs (although I also have a i40e NIC to test
> with). Do your AF_XDP patches work with zero-copy?

Tirtha's patches were for the regular driver, though I know that he at some point \
took a stab at the zero-copy driver, but that has likely rotted since it was a long \
time ago. For upstreaming, I suggest we start with the AF_XDP core support that \
Tirtha has. Maybe we can try it out with the mvneta support? And then after that \
people could add support to various drivers for this, both regular and zero-copy \
versions. What do you think?

We would in that case need something like this:

* Base AF_XDP mb support from Tirtha
* Selftests for this
* As the current selftests are based on veth, maybe we should add multi-buffer to \
veth. Or we just wait for Maciej's patches on the list [1] to get accepted. With \
those we can test any driver with loopback support. But does mvneta support loopback? \
If not it is veth, or add multi-buffer support to some other NIC driver.

[1] https://lore.kernel.org/bpf/20220616180609.905015-1-maciej.fijalkowski@intel.com/

/Magnus

> Kal
> 
> 
> On Mon, Jun 27, 2022 at 11:12 AM Sarkar, Tirthendu
> <tirthendu.sarkar@intel.com> wrote:
> > 
> > Hi Kal,
> > 
> > I have been working on implementing the XDP multi-buffer for i40e but got
> stuck with performance issues. I also have the AF_XDP patches and may be
> we can focus on them instead. What NIC are you working on?
> > 
> > + Magnus
> > 
> > Regards,
> > Tirtha
> > 
> > > -----Original Message-----
> > > From: Kal Cutter Conley <kal.conley@dectris.com>
> > > Sent: Wednesday, June 22, 2022 5:52 PM
> > > To: Fijalkowski, Maciej <maciej.fijalkowski@intel.com>
> > > Cc: eric@sage.org; Jesper Dangaard Brouer <jbrouer@redhat.com>; Toke
> > > Høiland-Jørgensen <toke@redhat.com>; Xdp <xdp-
> > > newbies@vger.kernel.org>; Sarkar, Tirthendu
> > > <tirthendu.sarkar@intel.com>
> > > Subject: Re: XDP multi-buffer and AF_XDP
> > > 
> > > Hi All,
> > > Does anyone know if any progress has been made with respect to
> > > multi- buffer support with AF_XDP? I would also like to help.
> > > 
> > > Kal
> > > 
> > > On Tue, Apr 5, 2022 at 1:12 PM Maciej Fijalkowski
> > > <maciej.fijalkowski@intel.com> wrote:
> > > > 
> > > > On Fri, Apr 01, 2022 at 09:52:02AM -0400, eric@sage.org wrote:
> > > > > On Fri, Apr 01, 2022 at 01:26:12PM +0000, Karlsson, Magnus wrote:
> > > > > > 
> > > > > > 
> > > > > > > -----Original Message-----
> > > > > > > From: Jesper Dangaard Brouer <jbrouer@redhat.com>
> > > > > > > Sent: Friday, April 1, 2022 3:13 PM
> > > > > > > To: Toke Høiland-Jørgensen <toke@redhat.com>; Kal Cutter
> > > > > > > Conley <kal.conley@dectris.com>; Xdp
> > > > > > > <xdp-newbies@vger.kernel.org>
> > > > > > > Cc: Brouer, Jesper <brouer@redhat.com>; Lorenzo Bianconi
> > > > > > > <lorenzo.bianconi@redhat.com>; Karlsson, Magnus
> > > > > > > <magnus.karlsson@intel.com>; eric.david.sage@gmail.com
> > > > > > > Subject: Re: XDP multi-buffer and AF_XDP
> > > > > > > 
> > > > > > > 
> > > > > > > On 01/04/2022 13.39, Toke Høiland-Jørgensen wrote:
> > > > > > > > Kal Cutter Conley <kal.conley@dectris.com> writes:
> > > > > > > > 
> > > > > > > > > > 
> > > > > > > > > > Hi,
> > > > > > > > > > We are very interested in receiving jumbo frames (> 8000
> > > > > > > > > > bytes) over AF_XDP. Does XDP multi-buffer support
> > > XDP_REDIRECT with AF_XDP?
> > > > > > > What
> > > > > > > > > > about in zero-copy mode?
> > > > > > > > > > 
> > > > > > > > > > Cheers,
> > > > > > > > > > Kal
> > > > > > > > > 
> > > > > > > > > Looking into this more I found this comment in the mlx5 driver:
> > > > > > > > > 
> > > > > > > > > /* Don't enable multi buffer on XDP_REDIRECT SQ, as it's
> > > > > > > > > not yet
> > > > > > > > > * supported by upstream, and there is no defined trigger
> > > > > > > > > to allow
> > > > > > > > > * transmitting redirected multi-buffer frames.
> > > > > > > > > */
> > > > > > > > > 
> > > > > > > > > So at least mlx5 does not yet support XDP multi-buffer
> > > > > > > > > with XDP_REDIRECT. What "upstream" support is required to
> > > > > > > > > get
> > > > > > > XDP_REDIRECT
> > > > > > > > > to work with XSKs?
> > > > > > > > 
> > > > > > > > Well, the initial patch set for multibuf explicitly
> > > > > > > > blocked XDP_REDIRECT between interfaces, which is what
> > > > > > > > that comment is referring to (the TX side).
> > > > > > > > 
> > > > > > > > For AF_XDP we'd also need to define the UAPI, and maybe
> > > > > > > > add a socket flag so the userspace program can signal to
> > > > > > > > the kernel that it understands it? Not sure about the details.
> > > > > > > > 
> > > > > > > > You're definitely not the only person who wants this,
> > > > > > > > though; adding in some people who may have a better idea
> > > > > > > > of the exact
> > > steps needed.
> > > > > > > 
> > > > > > > Cc. Eric Sage, as he also expressed interest in implementing this...
> > > > > > 
> > > > > > Adding Tirtha that has patches for the AF_XDP support of multi-
> buffer.
> > > > > > Though, he is currently integrating his i40e multi-buffer
> > > > > > driver support with Lorenzo's TX-patches that he sent as an
> > > > > > RFC. Latest I heard is that Tirtha is planning on submitting
> > > > > > this in a couple of weeks as a proper patch to the mailing
> > > > > > list. And after that, the focus is to brush up the AF_XDP and
> > > > > > ZC support patches as we stopped trying to track Lorenzo's
> > > > > > multi-buffer patches at version 13 out
> > > of 23 ;-).
> > > > > > We just could not keep up.
> > > > > 
> > > > > Ah, if there is anything I can do to help please let me know. My
> > > > > company needs this feature so I can work on it full time. I
> > > > > would love to
> > > help out however I can.
> > > > 
> > > > Hey Eric! We'll keep you in loop in terms of progress around this work.
> > > > 
> > > > > 
> > > > > Thanks,
> > > > > Eric Sage
> > > > > > 
> > > > > > > --Jesper
> > > > > > 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic