netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <brouer@redhat.com>
To: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: netdev@vger.kernel.org, jaswinder.singh@linaro.org,
	ard.biesheuvel@linaro.org, masami.hiramatsu@linaro.org,
	arnd@arndb.de, mykyta.iziumtsev@linaro.org,
	bjorn.topel@intel.com, magnus.karlsson@intel.com,
	daniel@iogearbox.net, ast@kernel.org, brouer@redhat.com
Subject: Re: [net-next, PATCH 2/2, v2] net: socionext: add XDP support
Date: Wed, 12 Sep 2018 11:14:57 +0200	[thread overview]
Message-ID: <20180912111457.0121d9f3@redhat.com> (raw)
In-Reply-To: <1536742958-29887-3-git-send-email-ilias.apalodimas@linaro.org>

On Wed, 12 Sep 2018 12:02:38 +0300
Ilias Apalodimas <ilias.apalodimas@linaro.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

  reply	other threads:[~2018-09-12 14:18 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-12  9:02 [net-next, PATCH 0/2, v2] net: socionext: add XDP support Ilias Apalodimas
2018-09-12  9:02 ` [net-next, PATCH 1/2, v2] net: socionext: different approach on DMA Ilias Apalodimas
2018-09-12  9:02 ` [net-next, PATCH 2/2, v2] net: socionext: add XDP support Ilias Apalodimas
2018-09-12  9:14   ` Jesper Dangaard Brouer [this message]
2018-09-12  9:20     ` Ilias Apalodimas
2018-09-12  9:28       ` Björn Töpel
2018-09-12  9:25   ` Jesper Dangaard Brouer
2018-09-12  9:29     ` Ilias Apalodimas
2018-09-13 14:32       ` Jesper Dangaard Brouer
2018-09-13 15:36         ` Ilias Apalodimas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180912111457.0121d9f3@redhat.com \
    --to=brouer@redhat.com \
    --cc=ard.biesheuvel@linaro.org \
    --cc=arnd@arndb.de \
    --cc=ast@kernel.org \
    --cc=bjorn.topel@intel.com \
    --cc=daniel@iogearbox.net \
    --cc=ilias.apalodimas@linaro.org \
    --cc=jaswinder.singh@linaro.org \
    --cc=magnus.karlsson@intel.com \
    --cc=masami.hiramatsu@linaro.org \
    --cc=mykyta.iziumtsev@linaro.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).