[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180912111457.0121d9f3@redhat.com>
Date: Wed, 12 Sep 2018 11:14:57 +0200
From: Jesper Dangaard Brouer <brouer@...hat.com>
To: Ilias Apalodimas <ilias.apalodimas@...aro.org>
Cc: netdev@...r.kernel.org, jaswinder.singh@...aro.org,
ard.biesheuvel@...aro.org, masami.hiramatsu@...aro.org,
arnd@...db.de, mykyta.iziumtsev@...aro.org, bjorn.topel@...el.com,
magnus.karlsson@...el.com, daniel@...earbox.net, ast@...nel.org,
brouer@...hat.com
Subject: Re: [net-next, PATCH 2/2, v2] net: socionext: add XDP support
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),
> + 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
Powered by blists - more mailing lists