From: Ruslan Osmanov <rrosmanov@gmail.com>
To: dev@dpdk.org
Subject: [dpdk-dev] Fw: Using KNI with virtio-net-pci
Date: Sat, 4 Jun 2016 02:12:19 +0700 [thread overview]
Message-ID: <20160604021219.397afd60@asus> (raw)
Hi,
I had posted the following to the users mailing list a couple of days
ago, but there was no answer. My question contains references to the
DPDK source code, so I probably will not break the rules by
sending a copy to the dev mailing list.
Begin forwarded message:
Date: Thu, 2 Jun 2016 10:43:23 +0700
From: Ruslan Osmanov <rrosmanov@gmail.com>
To: users@dpdk.org
Subject: Using KNI with virtio-net-pci
Hi,
I'm going to develop a DPDK application on a laptop, but the laptop's
hardware is not supported by DPDK. Furtunately, DPDK supports
paravirtualized devices(http://www.dpdk.org/doc/nics) including
virtio-net.
So I'm trying to configure a QEMU guest for running the Kernel NIC
Interface(KNI) on a virtio-net-pci device. The problem is that the KNI
sample application doesn't accept the virtio-pci driver.
QEMU command:
eth_device=virtio-net-pci
exec qemu-system-x86_64 -enable-kvm \
-cpu host -smp 2 \
-vga std \
-mem-prealloc -mem-path /dev/hugepages \
-drive file=GentooVM.img,if=virtio \
-netdev user,id=vmnic,hostname=gentoo \
-device $eth_device,netdev=vmnic \
-m 1024M \
-monitor stdio \
-name "Gentoo VM"
Running the KNI sample application in the guest:
sudo ./examples/kni/build/app/kni -c 0x3 -n 4 -- \
-P -p 0x1 --config="(0,0,1)"
EAL: Detected lcore 0 as core 0 on socket 0
EAL: Detected lcore 1 as core 0 on socket 0
EAL: Support maximum 128 logical core(s) by configuration.
EAL: Detected 2 lcore(s)
EAL: Probing VFIO support...
EAL: IOMMU type 1 (Type 1) is supported
EAL: IOMMU type 8 (No-IOMMU) is not supported
EAL: VFIO support initialized
EAL: Setting up physically contiguous memory...
...
EAL: WARNING: cpu flags constant_tsc=yes nonstop_tsc=no -> using
unreliable clock cycles !
EAL: Master lcore 0 is ready (tid=657d58c0;cpuset=[0])
PMD: rte_igbvf_pmd_init(): >>
EAL: lcore 1 is ready (tid=305ff700;cpuset=[1])
EAL: PCI device 0000:00:03.0 on NUMA socket -1
EAL: probe driver: 1af4:1000 rte_virtio_pmd
EAL: Not managed by a supported kernel driver(0), skipped
PMD: virtio_read_caps(): failed to map pci device!
PMD: vtpci_init(): trying with legacy virtio pci.
Segmentation fault
$ lspci
...
00:03.0 Ethernet controller: Red Hat, Inc Virtio network device
I've noticed that pci_scan_one() function sets dev->kdrv =
RTE_KDRV_NONE in lib/librte_eal/linuxapp/eal/eal_pci.c, while the
driver is detected as virtio-pci
(from /sys/bus/pci/devices/0000:00:03.0/driver).
Is it even possible to run KNI with virtio-net-pci device?
If it's impossible, then are there other options?
--
Ruslan Osmanov
--
Ruslan Osmanov
reply other threads:[~2016-06-03 19:12 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20160604021219.397afd60@asus \
--to=rrosmanov@gmail.com \
--cc=dev@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).