DPDK usage discussions
 help / color / mirror / Atom feed
From: Andrew Rybchenko <arybchenko@solarflare.com>
To: Chris Hall <chris.hall@stackpath.com>, "users@dpdk.org" <users@dpdk.org>
Subject: Re: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
Date: Thu, 9 Feb 2017 09:48:13 +0300	[thread overview]
Message-ID: <69f3bb6c-337a-28c1-bbae-b2dcfc2f064d@solarflare.com> (raw)
In-Reply-To: <BN6PR1001MB23211B7BCC262B741960187392420@BN6PR1001MB2321.namprd10.prod.outlook.com>

Hello Chris,

On 02/09/2017 02:14 AM, Chris Hall wrote:
> I’m having a bit of trouble running the l3fwd example program, I keep getting the error “rte_eth_rx_queue_setup: err=-22”
> No matter what options I supply. Wondering if I’m missing something ?

The problem is that almost all (all except testpmd which has 
command-line option to override default) DPDK example application use 
hardcoded number of the Rx/Tx descriptors instead of usage of limits 
advertised by PMD in rte_eth_dev_info_get() (structure rte_eth_dev_info, 
member rx_desc_lim). The following tiny patch solves the problem, but it 
is still hardcode (better and right solution is to write few lines of 
code which adjust defaults using information provided by the PMD - we 
have plans, since sfc_efx PMD is affected, to run through example 
applications and suggest patches)

===
diff --git a/examples/l3fwd/main.c b/examples/l3fwd/main.c
index a50d628..1cc6465 100644
--- a/examples/l3fwd/main.c
+++ b/examples/l3fwd/main.c
@@ -82,7 +82,7 @@
  /*
   * Configurable number of RX/TX ring descriptors
   */
-#define RTE_TEST_RX_DESC_DEFAULT 128
+#define RTE_TEST_RX_DESC_DEFAULT 512
  #define RTE_TEST_TX_DESC_DEFAULT 512

  #define MAX_TX_QUEUE_PER_PORT RTE_MAX_ETHPORTS
===

Andrew.

  parent reply	other threads:[~2017-02-09  6:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-08 23:14 Chris Hall
2017-02-09  5:22 ` Rosen, Rami
2017-02-09  6:48 ` Andrew Rybchenko [this message]
2017-02-10  0:05 Chris Hall
2017-02-10  6:46 ` Andrew Rybchenko

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=69f3bb6c-337a-28c1-bbae-b2dcfc2f064d@solarflare.com \
    --to=arybchenko@solarflare.com \
    --cc=chris.hall@stackpath.com \
    --cc=users@dpdk.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).