[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJ+HfNiB1wPG9z+pFLbiA332mF-sv2s_=RAOdqZKBASah3QFAw@mail.gmail.com>
Date: Wed, 12 Sep 2018 11:28:50 +0200
From: Björn Töpel <bjorn.topel@...il.com>
To: Ilias Apalodimas <ilias.apalodimas@...aro.org>
Cc: Jesper Dangaard Brouer <brouer@...hat.com>,
Netdev <netdev@...r.kernel.org>,
Jaswinder Brar <jaswinder.singh@...aro.org>,
Ard Biesheuvel <ard.biesheuvel@...aro.org>,
Masami Hiramatsu <masami.hiramatsu@...aro.org>,
Arnd Bergmann <arnd@...db.de>,
MykytaI Iziumtsev <mykyta.iziumtsev@...aro.org>,
Björn Töpel <bjorn.topel@...el.com>,
"Karlsson, Magnus" <magnus.karlsson@...el.com>,
Daniel Borkmann <daniel@...earbox.net>, ast@...nel.org
Subject: Re: [net-next, PATCH 2/2, v2] net: socionext: add XDP support
Den ons 12 sep. 2018 kl 11:21 skrev Ilias Apalodimas
<ilias.apalodimas@...aro.org>:
>
> On Wed, Sep 12, 2018 at 11:14:57AM +0200, Jesper Dangaard Brouer wrote:
> > On Wed, 12 Sep 2018 12:02:38 +0300
> > Ilias Apalodimas <ilias.apalodimas@...aro.org> wrote:
> >
> > > @@ -1003,20 +1076,29 @@ static int netsec_setup_rx_dring(struct netsec_priv *priv)
> > > u16 len;
> > >
> > > buf = netsec_alloc_rx_data(priv, &dma_handle, &len);
> > > - if (!buf) {
> > > - netsec_uninit_pkt_dring(priv, NETSEC_RING_RX);
> > > + if (!buf)
> > > goto err_out;
> > > - }
> > > desc->dma_addr = dma_handle;
> > > desc->addr = buf;
> > > desc->len = len;
> > > }
> > >
> > > netsec_rx_fill(priv, 0, DESC_NUM);
> > > + err = xdp_rxq_info_reg(&dring->xdp_rxq, priv->ndev, 0);
> >
> > Do you only have 1 RX queue? (last arg to xdp_rxq_info_reg is 0),
> >
> >
> Yes the current driver is only supporting a single queue (same for Tx)
XDP and skbuff path sharing the same queue? You'll probably need some
means of synchronization between the .ndo_xmit_xdp and .ndo_start_xmit
implementations. And it looks like .ndo_xmit_xdp is missing!
Björn
> > > + if (err)
> > > + goto err_out;
> > > +
> > > + err = xdp_rxq_info_reg_mem_model(&dring->xdp_rxq, MEM_TYPE_PAGE_SHARED,
> > > + NULL);
> > > + if (err) {
> > > + xdp_rxq_info_unreg(&dring->xdp_rxq);
> > > + goto err_out;
> > > + }
> > >
> > > return 0;
> > >
> >
> >
> > --
> > Best regards,
> > Jesper Dangaard Brouer
> > MSc.CS, Principal Kernel Engineer at Red Hat
> > LinkedIn: http://www.linkedin.com/in/brouer
>
>
> Thanks for looking at this
>
> /Ilias
Powered by blists - more mailing lists