[dpdk-dev] Error message "virtio-net device is already used by another driver"

Srinivasan J srinidpdk at gmail.com
Wed Dec 4 05:37:35 CET 2013


I am using Virtual Box Version 4.2.18 r88780, dpdk-1.5.1r1 and Fedora
19 with 3.11.9 kernel. I have one e1000 and one virtio-net NIC eth2
and eth3 respectively. eth2 is used for ssh access to the VM. I am
trying to get testpmd working on eth3 using the librte_pmd_virtio.so
driver. I have changed the defconfig_i686-default-linuxapp-gcc file to
disable the native virtio driver. I am getting the "virtio-net device
is already used by another driver" message. Any idea what could be
wrong? Any help is appreciated.

Thanks,
Srini

[root at localhost dpdk-1.5.1r1]# ./build/app/testpmd --no-huge -c 0x3 -n
1  --use-device 0000:00:0a.0 -d ./librte_pmd_virtio.so --
--disable-hw-vlan --disable-rss -i --rxq=1 --txq=1 --rxd=256 --txd=256
EAL: Cannot read numa node link for lcore 0 - using physical package id instead
EAL: Detected lcore 0 as core 0 on socket 0
EAL: Cannot read numa node link for lcore 1 - using physical package id instead
EAL: Detected lcore 1 as core 1 on socket 0
EAL: Skip lcore 2 (not detected)
EAL: Skip lcore 3 (not detected)
EAL: Skip lcore 4 (not detected)
EAL: Skip lcore 5 (not detected)
EAL: Skip lcore 6 (not detected)
EAL: Skip lcore 7 (not detected)
EAL: Skip lcore 8 (not detected)
EAL: Skip lcore 9 (not detected)
EAL: Skip lcore 10 (not detected)
EAL: Skip lcore 11 (not detected)
EAL: Skip lcore 12 (not detected)
EAL: Skip lcore 13 (not detected)
EAL: Skip lcore 14 (not detected)
EAL: Skip lcore 15 (not detected)
EAL: Skip lcore 16 (not detected)
EAL: Skip lcore 17 (not detected)
EAL: Skip lcore 18 (not detected)
EAL: Skip lcore 19 (not detected)
EAL: Skip lcore 20 (not detected)
EAL: Skip lcore 21 (not detected)
EAL: Skip lcore 22 (not detected)
EAL: Skip lcore 23 (not detected)
EAL: Skip lcore 24 (not detected)
EAL: Skip lcore 25 (not detected)
EAL: Skip lcore 26 (not detected)
EAL: Skip lcore 27 (not detected)
EAL: Skip lcore 28 (not detected)
EAL: Skip lcore 29 (not detected)
EAL: Skip lcore 30 (not detected)
EAL: Skip lcore 31 (not detected)
EAL: Skip lcore 32 (not detected)
EAL: Skip lcore 33 (not detected)
EAL: Skip lcore 34 (not detected)
EAL: Skip lcore 35 (not detected)
EAL: Skip lcore 36 (not detected)
EAL: Skip lcore 37 (not detected)
EAL: Skip lcore 38 (not detected)
EAL: Skip lcore 39 (not detected)
EAL: Skip lcore 40 (not detected)
EAL: Skip lcore 41 (not detected)
EAL: Skip lcore 42 (not detected)
EAL: Skip lcore 43 (not detected)
EAL: Skip lcore 44 (not detected)
EAL: Skip lcore 45 (not detected)
EAL: Skip lcore 46 (not detected)
EAL: Skip lcore 47 (not detected)
EAL: Skip lcore 48 (not detected)
EAL: Skip lcore 49 (not detected)
EAL: Skip lcore 50 (not detected)
EAL: Skip lcore 51 (not detected)
EAL: Skip lcore 52 (not detected)
EAL: Skip lcore 53 (not detected)
EAL: Skip lcore 54 (not detected)
EAL: Skip lcore 55 (not detected)
EAL: Skip lcore 56 (not detected)
EAL: Skip lcore 57 (not detected)
EAL: Skip lcore 58 (not detected)
EAL: Skip lcore 59 (not detected)
EAL: Skip lcore 60 (not detected)
EAL: Skip lcore 61 (not detected)
EAL: Skip lcore 62 (not detected)
EAL: Skip lcore 63 (not detected)
EAL: Setting up memory...
EAL: TSC frequency is ~2370929 KHz
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: WARNING: Master core has no memory on local socket!
librte_pmd_virtio version 1.1
        Copyright 2013 6WIND S.A. provided without warranty.
EAL: Master core 0 is ready (tid=b774e800)
EAL: Core 1 is ready (tid=b2f0eb40)
EAL: PCI device 0000:00:0a.0 on NUMA socket -1
EAL:   probe driver: 1af4:1000 rte_virtio_net_pmd
start = d060
end   = d07f
Interactive-mode selected
Configuring Port 0 (socket -1)
PANIC in virtio_alloc_queue():
0000:00:0a.0: this virtio-net device is already used by another driver
8: [./build/app/testpmd() [0x805b82d]]
7: [/lib/libc.so.6(__libc_start_main+0xf3) [0x4b45c963]]
6: [./build/app/testpmd(main+0x3e4) [0x805b5a4]]
5: [./build/app/testpmd(start_port+0x145) [0x805def5]]
4: [./librte_pmd_virtio.so(+0x8b1e) [0xb2f17b1e]]
3: [./librte_pmd_virtio.so(+0x3d68) [0xb2f12d68]]
2: [./build/app/testpmd(__rte_panic+0x5c) [0x805b186]]
1: [./build/app/testpmd(rte_dump_stack+0x1c) [0x80d68bc]]
Aborted
[root at localhost dpdk-1.5.1r1]#

+++ config/defconfig_i686-default-linuxapp-gcc  2013-12-04
09:34:44.113127888 +0530
@@ -144,7 +144,7 @@
 # Compile generic ethernet library
 #
 CONFIG_RTE_LIBRTE_ETHER=y
-CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=n
+CONFIG_RTE_LIBRTE_ETHDEV_DEBUG=y
 CONFIG_RTE_MAX_ETHPORTS=32
 CONFIG_RTE_LIBRTE_IEEE1588=n
 CONFIG_RTE_ETHDEV_QUEUE_STAT_CNTRS=16
@@ -177,12 +177,12 @@
 #
 # Compile burst-oriented VIRTIO PMD driver
 #
-CONFIG_RTE_LIBRTE_VIRTIO_PMD=y
-CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_INIT=n
-CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_RX=n
-CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_TX=n
-CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DRIVER=n
-CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=n
+CONFIG_RTE_LIBRTE_VIRTIO_PMD=n
+CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_INIT=y
+CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_RX=y
+CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_TX=y
+CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DRIVER=y
+CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=y

#
[root at localhost dpdk-1.5.1r1]$ uname -a
Linux localhost.localdomain 3.11.9-200.fc19.i686 #1 SMP Wed Nov 20
21:41:11 UTC 2013 i686 i686 i386 GNU/Linux
[root at localhost dpdk-1.5.1r1]# cat /proc/ioports
0000-001f : dma1
0020-0021 : pic1
0040-0043 : timer0
0050-0053 : timer1
0060-0060 : keyboard
0064-0064 : keyboard
0070-0071 : rtc_cmos
  0070-0071 : rtc0
0080-008f : dma page reg
00a0-00a1 : pic2
00c0-00df : dma2
00f0-00ff : fpu
0170-0177 : 0000:00:01.1
  0170-0177 : ata_piix
01f0-01f7 : 0000:00:01.1
  01f0-01f7 : ata_piix
0376-0376 : 0000:00:01.1
  0376-0376 : ata_piix
03c0-03df : vga+
03f6-03f6 : 0000:00:01.1
  03f6-03f6 : ata_piix
03f8-03ff : serial
0cf8-0cff : PCI conf1
4000-4003 : ACPI PM1a_EVT_BLK
4004-4005 : ACPI PM1a_CNT_BLK
4008-400b : ACPI PM_TMR
4020-4021 : ACPI GPE0_BLK
d000-d00f : 0000:00:01.1
  d000-d00f : ata_piix
d020-d03f : 0000:00:04.0
d040-d047 : 0000:00:09.0
  d040-d047 : e1000
d060-d07f : 0000:00:0a.0
  d060-d07f : virtio-pci
d080-d087 : 0000:00:0d.0
  d080-d087 : ahci
d090-d097 : 0000:00:0d.0
  d090-d097 : ahci
d0a0-d0af : 0000:00:0d.0
  d0a0-d0af : ahci
[root at localhost dpdk-1.5.1r1]# lspci
00:00.0 Host bridge: Intel Corporation 440FX - 82441FX PMC [Natoma] (rev 02)
00:01.0 ISA bridge: Intel Corporation 82371SB PIIX3 ISA [Natoma/Triton II]
00:01.1 IDE interface: Intel Corporation 82371AB/EB/MB PIIX4 IDE (rev 01)
00:02.0 VGA compatible controller: InnoTek Systemberatung GmbH
VirtualBox Graphics Adapter
00:04.0 System peripheral: InnoTek Systemberatung GmbH VirtualBox Guest Service
00:06.0 USB controller: Apple Inc. KeyLargo/Intrepid USB
00:07.0 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ACPI (rev 08)
00:09.0 Ethernet controller: Intel Corporation 82540EM Gigabit
Ethernet Controller (rev 02)
00:0a.0 Ethernet controller: Red Hat, Inc Virtio network device
00:0d.0 SATA controller: Intel Corporation 82801HM/HEM (ICH8M/ICH8M-E)
SATA Controller [AHCI mode] (rev 02)
[root at localhost dpdk-1.5.1r1]$ ifconfig
eth2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.16.32.137  netmask 255.255.255.0  broadcast 10.16.32.255
        inet6 fe80::a00:27ff:fe7a:5f9c  prefixlen 64  scopeid 0x20<link>
        ether 08:00:27:7a:5f:9c  txqueuelen 1000  (Ethernet)
        RX packets 6920  bytes 640766 (625.7 KiB)
        RX errors 0  dropped 17  overruns 0  frame 0
        TX packets 5011  bytes 886981 (866.1 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 0  (Local Loopback)
        RX packets 2  bytes 100 (100.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2  bytes 100 (100.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

[root at localhost dpdk-1.5.1r1]$ ls -l /sys/class/net/
total 0
lrwxrwxrwx 1 root root 0 Dec  4 03:08 eth2 ->
../../devices/pci0000:00/0000:00:09.0/net/eth2
lrwxrwxrwx 1 root root 0 Dec  4 03:08 eth3 ->
../../devices/pci0000:00/0000:00:0a.0/virtio0/net/eth3
lrwxrwxrwx 1 root root 0 Dec  4 03:08 lo -> ../../devices/virtual/net/lo


lspci -vv

00:09.0 Ethernet controller: Intel Corporation 82540EM Gigabit
Ethernet Controller (rev 02)
        Subsystem: Intel Corporation PRO/1000 MT Desktop Adapter
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop-
ParErr- Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz+ UDF- FastB2B- ParErr- DEVSEL=medium
>TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 64 (63750ns min)
        Interrupt: pin A routed to IRQ 17
        Region 0: Memory at f0420000 (32-bit, non-prefetchable) [size=128K]
        Region 2: I/O ports at d040 [size=8]
        Capabilities: [dc] Power Management version 2
                Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA
PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [e4] PCI-X non-bridge device
                Command: DPERE- ERO+ RBC=512 OST=1
                Status: Dev=ff:1f.0 64bit- 133MHz- SCD- USC- DC=simple
DMMRBC=2048 DMOST=1 DMCRS=8 RSCEM- 266MHz- 533MHz-
        Kernel driver in use: e1000

00:0a.0 Ethernet controller: Red Hat, Inc Virtio network device
        Subsystem: Red Hat, Inc Device 0001
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop-
ParErr- Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort-
<TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 64
        Interrupt: pin A routed to IRQ 18
        Region 0: I/O ports at d060 [size=32]
        Capabilities: [80] #00 [0000]
        Kernel driver in use: virtio-pci


More information about the dev mailing list