DPDK patches and discussions
 help / color / mirror / Atom feed
From: tom.barbette@ulg.ac.be
To: dev@dpdk.org
Cc: katsikas@kth.se
Subject: [dpdk-dev] Bug in ring-based pmd?
Date: Thu, 3 Dec 2015 17:43:30 +0100 (CET)	[thread overview]
Message-ID: <1047692251.36459228.1449161010722.JavaMail.zimbra@ulg.ac.be> (raw)
In-Reply-To: <1315814008.36444218.1449158572704.JavaMail.zimbra@ulg.ac.be>

Hi list,

I try to make two DPDK process work together through a ring-based veth.

The first one fills the ring with generated packets :
./bin/click -n 4 -c 0x1 --proc-type=auto --vdev=eth_ring_0 -- conf/flow/veth-out.click
The second one reads them :
./bin/click -n 4 -c 0x2 --proc-type=auto --vdev=eth_ring_0 -- conf/flow/veth-in.click

The first one goes well, and block after a while as the ring is full.

But when I start the second one, I get :

Program received signal SIGSEGV, Segmentation fault.
0x00000000006a4b34 in rte_eth_rx_burst (nb_pkts=32, rx_pkts=0x7fffffffe2d0, queue_id=0, 
    port_id=0 '\000')
    at /home/tom/dpdk//x86_64-native-linuxapp-gcc/include/rte_ethdev.h:2418
2418				rx_pkts, nb_pkts);

With DPDK 2.0 and 2.1.

With DPDK 2.2rc2 It works exactly one time every two launches. When it fails, rte_eth_rx_burst gives me some packet but after some time, one call to  rte_eth_rx_burst will return 32 (=my burst parameter) but the first mbuf pointer is null (pkts[0]=0) and the following mubfs* are garbage.

I didn't load any real NIC during those test. 

I found out that the link_status is 1 in the primary process and 0 in the secondary one, if it may be of any help...

Relevant part of the primary process is :
EAL: Support maximum 128 logical core(s) by configuration.
EAL: Detected 16 lcore(s)
EAL: Auto-detected process type: PRIMARY
EAL: VFIO modules not all loaded, skip VFIO support...
EAL: Setting up physically contiguous memory...
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffff4a00000 (size = 0x200000)
EAL: Ask a virtual area of 0x71400000 bytes
EAL: Virtual area found at 0x7fff83400000 (size = 0x71400000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7fff83000000 (size = 0x200000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7fff82c00000 (size = 0x200000)
EAL: Ask a virtual area of 0x18d800000 bytes
EAL: Virtual area found at 0x7ffdf5200000 (size = 0x18d800000)
EAL: Ask a virtual area of 0x400000 bytes
EAL: Virtual area found at 0x7ffdf4c00000 (size = 0x400000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffdf4800000 (size = 0x200000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffdf4400000 (size = 0x200000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffdf4000000 (size = 0x200000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffdf3c00000 (size = 0x200000)
EAL: Ask a virtual area of 0x200000 bytes
EAL: Virtual area found at 0x7ffdf3800000 (size = 0x200000)
EAL: Requesting 4096 pages of size 2MB from socket 0
[New Thread 0x7ffff69a7700 (LWP 26992)]
EAL: TSC frequency is ~2398609 KHz
EAL: Master lcore 0 is ready (tid=f7fdf900;cpuset=[0])
PMD: Initializing pmd_ring for eth_ring_0
PMD: Creating rings-backed ethdev on numa socket 0
EAL: PCI device 0000:03:00.0 on NUMA socket 0
EAL:   probe driver: 8086:1584 rte_i40e_pmd
EAL:   Not managed by a supported kernel driver, skipped
EAL: PCI device 0000:03:00.1 on NUMA socket 0
EAL:   probe driver: 8086:1584 rte_i40e_pmd
EAL:   Not managed by a supported kernel driver, skipped
EAL: PCI device 0000:03:00.2 on NUMA socket 0
EAL:   probe driver: 8086:1584 rte_i40e_pmd
EAL:   Not managed by a supported kernel driver, skipped
EAL: PCI device 0000:03:00.3 on NUMA socket 0
EAL:   probe driver: 8086:1584 rte_i40e_pmd
EAL:   Not managed by a supported kernel driver, skipped
Initializing DPDK (mempool, ...)
ToDPDKDevice@2: congestion warning (ring is full)


For the secondary :

EAL: Support maximum 128 logical core(s) by configuration.
EAL: Detected 16 lcore(s)
EAL: Auto-detected process type: SECONDARY
EAL: VFIO modules not all loaded, skip VFIO support...
EAL: Setting up physically contiguous memory...
EAL: Analysing 4096 files
EAL: Mapped segment 0 of size 0x200000
EAL: Mapped segment 1 of size 0x71400000
EAL: Mapped segment 2 of size 0x200000
EAL: Mapped segment 3 of size 0x200000
EAL: Mapped segment 4 of size 0x18d800000
EAL: Mapped segment 5 of size 0x400000
EAL: Mapped segment 6 of size 0x200000
EAL: Mapped segment 7 of size 0x200000
EAL: Mapped segment 8 of size 0x200000
EAL: Mapped segment 9 of size 0x200000
EAL: Mapped segment 10 of size 0x200000
EAL: memzone_reserve_aligned_thread_unsafe(): memzone <RG_MP_log_history> already exists
RING: Cannot reserve memory
[New Thread 0x7ffff69a7700 (LWP 27022)]
EAL: TSC frequency is ~2398608 KHz
EAL: Master lcore 1 is ready (tid=f7fdf900;cpuset=[2])
PMD: Initializing pmd_ring for eth_ring_0
EAL: memzone_reserve_aligned_thread_unsafe(): memzone <RG_ETH_RXTX0_eth_ring_0> already exists
RING: Cannot reserve memory
PMD: Attach to pmd_ring for eth_ring_0
PMD: Creating rings-backed ethdev on numa socket 0
(...)
Initializing DPDK (<-- attach to the mempool of the first process using mempool_walk)
(First read :)
Program received signal SIGSEGV, Segmentation fault.
0x000000000068d3f6 in rte_eth_rx_burst (nb_pkts=32, rx_pkts=0x7fffffffe220, queue_id=0, 
    port_id=0 '\000')
    at /home/tom/dpdk//x86_64-native-linuxapp-gcc/include/rte_ethdev.h:2532
2532				rx_pkts, nb_pkts);


Thanks !
Tom

           reply	other threads:[~2015-12-03 16:43 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <1315814008.36444218.1449158572704.JavaMail.zimbra@ulg.ac.be>]

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=1047692251.36459228.1449161010722.JavaMail.zimbra@ulg.ac.be \
    --to=tom.barbette@ulg.ac.be \
    --cc=dev@dpdk.org \
    --cc=katsikas@kth.se \
    /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).