[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
On Tue, Jan 27, 2015 at 10:02:24AM +, Stephen Hemminger wrote: > On Mon, 26 Jan 2015 19:06:12 -0800 > Matthew Hall wrote: > > > Thank you so much for this, using virtio drivers in DPDK has been messy and > > unpleasant in the past, and you clearly wrote a lot of nice new code to > > help > > improve it all. > > > > Previously I'd reported a bug, where all RTE virtio drivers I tried (A and > > B, > > because I did not know C existed), failed to work with the virtio-net > > interfaces exposed in VirtualBox, due to various strange errors, and they > > all > > only worked with the virtio-net interfaces from qemu. > > I suspect a problem with features required (and not supported by VirtualBox). > Build driver with debug enabled and send the log please. Hi Stephen, Here is everything that happened when I tried it before. http://dpdk.org/ml/archives/dev/2014-October/006623.html Matthew.
[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
This is the patch set for single virtio implementation. Why we need single virtio? As we know currently there are at least 3 virtio PMD driver implementations: A) lib/librte_pmd_virtio(refer as virtio A); B) virtio_net_pmd by 6wind(refer as virtio B); C) virtio by Brocade/vyatta(refer as virtio C); Integrating 3 implementations into one could reduce the maintaining cost and time, in other hand, user don't need practice their application on 3 variant one by one to see which one is the best for them; What's the status? Currently virtio A has covered most features of virtio B except for using port io to get pci resource, so there is a patch(17/22) to resolve it. But on the other hand there are a few differences between virtio A and virtio C, it needs integrate features/codes of virtio C into virtio A. This patch set bases on two original RFC patch sets from Stephen Hemminger[stephen at networkplumber.org] Refer to [http://dpdk.org/ml/archives/dev/2014-August/004845.html ] for the original one. This patch set also resolves some conflict with latest codes, removed duplicated codes, fix some issues in original codes. What this patch set contains: === 1) virtio: Rearrange resource initialization, it extracts a function to setup PCI resources; 2) virtio: Use weaker barriers, as DPDK driver only has to deal with the case of running on PCI and with SMP, In this case, the code can use the weaker barriers instead of using hard (fence) barriers. This may help performance a bit; 3) virtio: Allow starting with link down, other driver has similar behavior; 4) virtio: Add support for Link State interrupt; 5) ether: Add soft vlan encap/decap functions, it helps if HW don't support vlan strip; 6) virtio: Use software vlan stripping; 7) virtio: Remove unnecessary adapter structure; 8) virtio: Remove redundant vq_alignment, as vq alignment is always 4K, so use constant when needed; 9) virtio: Fix how states are handled during initialization, this is to match Linux kernel; 10) virtio: Make vtpci_get_status a local function as it is used in one file; 11) virtio: Check for packet headroom at compile time; 12) virtio: Move allocation before initialization to avoid being stuck in middle of virtio init; 13) virtio: Add support for vlan filtering; 14) virtio: Add support for multiple mac addresses; 15) virtio: Add ability to set MAC address; 16) virtio: Free mbuf's with threshold, this makes its behavior more like ixgbe; 17) virtio: Use port IO to get PCI resource for security reasons and match virtio-net-pmd; 18) virtio: Fix descriptor index issue; 19) ether: Fix vlan strip/insert issue; 20) example/vhost: Avoid inserting vlan twice and guest and host; 21) example/vhost: Add vlan-strip cmd line option to turn on/off vlan strip on host; 22) virtio: Use soft vlan strip in mergeable Rx path, this makes it has consistent logic with the normal Rx path. Changes in v2: 23) virtio: Fix zero copy break issue, the vring should be ready before virtio PMD set the status of DRIVER_OK; 24) virtio: Remove unnecessary hotspots in data path. Changchun Ouyang (8): virtio: Use port IO to get PCI resource. virtio: Fix descriptor index issue ether: Fix vlan strip/insert issue example/vhost: Avoid inserting vlan twice example/vhost: Add vlan-strip cmd line option virtio: Use soft vlan strip in mergeable Rx path virtio: Fix zero copy break issue virtio: Remove hotspots Stephen Hemminger (16): virtio: Rearrange resource initialization virtio: Use weaker barriers virtio: Allow starting with link down virtio: Add support for Link State interrupt ether: Add soft vlan encap/decap functions virtio: Use software vlan stripping virtio: Remove unnecessary adapter structure virtio: Remove redundant vq_alignment virtio: Fix how states are handled during initialization virtio: Make vtpci_get_status local virtio: Check for packet headroom at compile time virtio: Move allocation before initialization virtio: Add support for vlan filtering virtio: Add suport for multiple mac addresses virtio: Add ability to set MAC address virtio: Free mbuf's with threshold config/common_linuxapp | 2 + examples/vhost/main.c | 39 ++- lib/librte_eal/common/include/rte_pci.h | 4 + lib/librte_eal/linuxapp/eal/eal_pci.c | 5 +- lib/librte_ether/rte_ethdev.h | 8 + lib/librte_ether/rte_ether.h| 76 + lib/librte_pmd_virtio/virtio_ethdev.c | 492 +--- lib/librte_pmd_virtio/virtio_ethdev.h | 12 +- lib/librte_pmd_virtio/virtio_pci.c | 20 +- lib/librte_pmd_virtio/virtio_pci.h | 8 +- lib/librte_pmd_virtio/virtio_rxtx.c | 139 ++--- lib/librte_pmd_virtio/virtqueue.h | 59 +++- 12 files changed, 693 insertions(+), 171 deletions(-) -- 1.8.4.
[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
On Mon, 26 Jan 2015 19:06:12 -0800 Matthew Hall wrote: > Thank you so much for this, using virtio drivers in DPDK has been messy and > unpleasant in the past, and you clearly wrote a lot of nice new code to help > improve it all. > > Previously I'd reported a bug, where all RTE virtio drivers I tried (A and B, > because I did not know C existed), failed to work with the virtio-net > interfaces exposed in VirtualBox, due to various strange errors, and they all > only worked with the virtio-net interfaces from qemu. I suspect a problem with features required (and not supported by VirtualBox). Build driver with debug enabled and send the log please.
[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
On 1/26/15, 8:06 PM, "Matthew Hall" wrote: >On Tue, Jan 27, 2015 at 10:35:40AM +0800, Ouyang Changchun wrote: >> This is the patch set for single virtio implementation. >> >> Why we need single virtio? >> >> As we know currently there are at least 3 virtio PMD driver >>implementations: >> A) lib/librte_pmd_virtio(refer as virtio A); >> B) virtio_net_pmd by 6wind(refer as virtio B); >> C) virtio by Brocade/vyatta(refer as virtio C); >> >> Integrating 3 implementations into one could reduce the maintaining >>cost and time, >> in other hand, user don't need practice their application on 3 variant >>one by one to see >> which one is the best for them; > >Thank you so much for this, using virtio drivers in DPDK has been messy >and >unpleasant in the past, and you clearly wrote a lot of nice new code to >help >improve it all. > >Previously I'd reported a bug, where all RTE virtio drivers I tried (A >and B, >because I did not know C existed), failed to work with the virtio-net >interfaces exposed in VirtualBox, due to various strange errors, and they >all >only worked with the virtio-net interfaces from qemu. > >I wanted to find out if we managed to fix this other problem, because I >would >really like to use the Vagrant VM deployment tool >(https://www.vagrantup.com/) >to distribute my open-source DPDK based application to everyone in the >open source community. > >The better the out-of-box experience of practical community-created >DPDK-based >real-life example applications similar to mine, the more adoption of DPDK >and >better DPDK community we will be able to have as time marches forward. > >If we could manage to get it to work in VirtualBox, then I could surely >help >do some app-level testing on the new code, if we could see it in a test >branch >or test repo somewhere I could access it. There is an app note on how to get DPDK working in VirtualBox, it is a bit bumpy on getting it work. Here is the link: http://plvision.eu/blog/deploying-intel-dpdk-in-oracle-virtualbox/ I have not tried it, but it was suggested to me it should work. It will be nice if the new driver works better :-) > >Sincerely, >Matthew Hall
[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
On Tue, Jan 27, 2015 at 03:42:00AM +, Wiles, Keith wrote: > There is an app note on how to get DPDK working in VirtualBox, it is a bit > bumpy on getting it work. > Here is the link: > http://plvision.eu/blog/deploying-intel-dpdk-in-oracle-virtualbox/ > > I have not tried it, but it was suggested to me it should work. It will be > nice if the new driver works better :-) I already used a derivative of these directions... "cheated" and used the igb driver like they did. Unlike them I automated the entire process, including updating the base OS to latest kernel and recompiling against it, as well as auto-enabling the NICs, the SSE instruction sets, etc. etc. However their directions use an IGB NIC not a virtio-net NIC which would be much better for performance and resource consumption. So I really would be very very happy if we had a virtio-net which worked properly with both qemu and VirtualBox. Matthew.
[dpdk-dev] [PATCH v2 00/24] Single virtio implementation
On Tue, Jan 27, 2015 at 10:35:40AM +0800, Ouyang Changchun wrote: > This is the patch set for single virtio implementation. > > Why we need single virtio? > > As we know currently there are at least 3 virtio PMD driver implementations: > A) lib/librte_pmd_virtio(refer as virtio A); > B) virtio_net_pmd by 6wind(refer as virtio B); > C) virtio by Brocade/vyatta(refer as virtio C); > > Integrating 3 implementations into one could reduce the maintaining cost and > time, > in other hand, user don't need practice their application on 3 variant one by > one to see > which one is the best for them; Thank you so much for this, using virtio drivers in DPDK has been messy and unpleasant in the past, and you clearly wrote a lot of nice new code to help improve it all. Previously I'd reported a bug, where all RTE virtio drivers I tried (A and B, because I did not know C existed), failed to work with the virtio-net interfaces exposed in VirtualBox, due to various strange errors, and they all only worked with the virtio-net interfaces from qemu. I wanted to find out if we managed to fix this other problem, because I would really like to use the Vagrant VM deployment tool (https://www.vagrantup.com/) to distribute my open-source DPDK based application to everyone in the open source community. The better the out-of-box experience of practical community-created DPDK-based real-life example applications similar to mine, the more adoption of DPDK and better DPDK community we will be able to have as time marches forward. If we could manage to get it to work in VirtualBox, then I could surely help do some app-level testing on the new code, if we could see it in a test branch or test repo somewhere I could access it. Sincerely, Matthew Hall