DPDK usage discussions
 help / color / mirror / Atom feed
* Re: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
@ 2017-02-10  0:05 Chris Hall
  2017-02-10  6:46 ` Andrew Rybchenko
  0 siblings, 1 reply; 5+ messages in thread
From: Chris Hall @ 2017-02-10  0:05 UTC (permalink / raw)
  To: Andrew Rybchenko, users

Andrew,

Thanks again, I thought I had already applied these changes. Rebuilt everything, and l3fwd works as expected.
Is there a way to get any stats from l3fwd ?

Thanks
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
>s 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


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
  2017-02-10  0:05 [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22 Chris Hall
@ 2017-02-10  6:46 ` Andrew Rybchenko
  0 siblings, 0 replies; 5+ messages in thread
From: Andrew Rybchenko @ 2017-02-10  6:46 UTC (permalink / raw)
  To: Chris Hall, users

Chris,

On 02/10/2017 03:05 AM, Chris Hall wrote:
> Thanks again, I thought I had already applied these changes. Rebuilt 
> everything, and l3fwd works as expected.
>
> Is there a way to get any stats from l3fwd ?
>

I see no way to get any stats from the example app.

Regards,
Andrew.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
  2017-02-08 23:14 Chris Hall
  2017-02-09  5:22 ` Rosen, Rami
@ 2017-02-09  6:48 ` Andrew Rybchenko
  1 sibling, 0 replies; 5+ messages in thread
From: Andrew Rybchenko @ 2017-02-09  6:48 UTC (permalink / raw)
  To: Chris Hall, users

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.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
  2017-02-08 23:14 Chris Hall
@ 2017-02-09  5:22 ` Rosen, Rami
  2017-02-09  6:48 ` Andrew Rybchenko
  1 sibling, 0 replies; 5+ messages in thread
From: Rosen, Rami @ 2017-02-09  5:22 UTC (permalink / raw)
  To: Chris Hall, users

Hello, Chris,

First, there are several places in the rte_eth_rx_queue_setup() method where -22 (-EINVAL) is returned.
See: http://dpdk.org/browse/dpdk/tree/lib/librte_ether/rte_ethdev.c#n1083

I would suggest, as a first step,  that you will build dpdk with debug info for this method:
change CONFIG_RTE_LIBRTE_ETHDEV_DEBUG to be y in build/.config, and then run 
make clean and make, and then please run the l3fwd app again; if there is additional info in the log, please post it here if the info still does not help you solve the problem, as it might give a hint. Also please tell which DPDK version you are using.

Regards,
Rami Rosen

-----Original Message-----
From: users [mailto:users-bounces@dpdk.org] On Behalf Of Chris Hall
Sent: Thursday, February 09, 2017 01:14
To: users@dpdk.org
Subject: [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22

Hello,

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 ?

Using l3fwd from dpdk-next-net

Thanks in advance.
Chris


# dpdk-devbind -s

Network devices using DPDK-compatible driver ============================================
0000:04:00.0 'SFC9220' drv=igb_uio unused=sfc
0000:04:00.1 'SFC9220' drv=igb_uio unused=sfc


# x86_64-native-linuxapp-gcc/l3fwd -l 1,2 -n 4 -w04:00.0 -w04:00.1 -- -p 0x3 --config="(0,0,1),(1,0,2)"
EAL: Detected 40 lcore(s)
EAL: Probing VFIO support...
EAL: PCI device 0000:04:00.0 on NUMA socket 0
EAL:   probe driver: 1924:a03 net_sfc_efx
EAL: PCI device 0000:04:00.1 on NUMA socket 0
EAL:   probe driver: 1924:a03 net_sfc_efx
L3FWD: LPM or EM none selected, default LPM on Initializing port 0 ...
Creating queues: nb_rxq=1 nb_txq=2...
PMD: sfc_efx 0000:04:00.0 #0: LSC tracking using interrupts is disabled
PMD: sfc_efx 0000:04:00.0 #0: FCS stripping control not supported - always stripped Address:00:0F:53:43:9D:50, Destination:02:00:00:00:00:00, Allocated mbuf pool on socket 0
LPM: Adding route 0x01010100 / 24 (0)
LPM: Adding route 0x02010100 / 24 (1)
LPM: Adding route IPV6 / 48 (0)
LPM: Adding route IPV6 / 48 (1)
txq=1,0,0 txq=2,1,0
Initializing port 1 ...
Creating queues: nb_rxq=1 nb_txq=2...
PMD: sfc_efx 0000:04:00.1 #1: LSC tracking using interrupts is disabled
PMD: sfc_efx 0000:04:00.1 #1: FCS stripping control not supported - always stripped Address:00:0F:53:43:9D:51, Destination:02:00:00:00:00:01, txq=1,0,0 txq=2,1,0

Initializing rx queues on lcore 1 ...
rxq=0,0,0 EAL: Error - exiting with code: 1
  Cause: rte_eth_rx_queue_setup: err=-22, port=0


Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22
@ 2017-02-08 23:14 Chris Hall
  2017-02-09  5:22 ` Rosen, Rami
  2017-02-09  6:48 ` Andrew Rybchenko
  0 siblings, 2 replies; 5+ messages in thread
From: Chris Hall @ 2017-02-08 23:14 UTC (permalink / raw)
  To: users

Hello,

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 ?

Using l3fwd from dpdk-next-net

Thanks in advance.
Chris


# dpdk-devbind -s

Network devices using DPDK-compatible driver
============================================
0000:04:00.0 'SFC9220' drv=igb_uio unused=sfc
0000:04:00.1 'SFC9220' drv=igb_uio unused=sfc


# x86_64-native-linuxapp-gcc/l3fwd -l 1,2 -n 4 -w04:00.0 -w04:00.1 -- -p 0x3 --config="(0,0,1),(1,0,2)"
EAL: Detected 40 lcore(s)
EAL: Probing VFIO support...
EAL: PCI device 0000:04:00.0 on NUMA socket 0
EAL:   probe driver: 1924:a03 net_sfc_efx
EAL: PCI device 0000:04:00.1 on NUMA socket 0
EAL:   probe driver: 1924:a03 net_sfc_efx
L3FWD: LPM or EM none selected, default LPM on
Initializing port 0 ...
Creating queues: nb_rxq=1 nb_txq=2...
PMD: sfc_efx 0000:04:00.0 #0: LSC tracking using interrupts is disabled
PMD: sfc_efx 0000:04:00.0 #0: FCS stripping control not supported - always stripped
Address:00:0F:53:43:9D:50, Destination:02:00:00:00:00:00, Allocated mbuf pool on socket 0
LPM: Adding route 0x01010100 / 24 (0)
LPM: Adding route 0x02010100 / 24 (1)
LPM: Adding route IPV6 / 48 (0)
LPM: Adding route IPV6 / 48 (1)
txq=1,0,0 txq=2,1,0
Initializing port 1 ...
Creating queues: nb_rxq=1 nb_txq=2...
PMD: sfc_efx 0000:04:00.1 #1: LSC tracking using interrupts is disabled
PMD: sfc_efx 0000:04:00.1 #1: FCS stripping control not supported - always stripped
Address:00:0F:53:43:9D:51, Destination:02:00:00:00:00:01, txq=1,0,0 txq=2,1,0

Initializing rx queues on lcore 1 ...
rxq=0,0,0 EAL: Error - exiting with code: 1
  Cause: rte_eth_rx_queue_setup: err=-22, port=0


Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-02-10  6:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-10  0:05 [dpdk-users] l3fwd rte_eth_rx_queue_setup: err=-22 Chris Hall
2017-02-10  6:46 ` Andrew Rybchenko
  -- strict thread matches above, loose matches on Subject: below --
2017-02-08 23:14 Chris Hall
2017-02-09  5:22 ` Rosen, Rami
2017-02-09  6:48 ` Andrew Rybchenko

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).