Re: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

2018-04-10 Thread Wei Xu
On Tue, Apr 10, 2018 at 11:46:47AM +0800, Jason Wang wrote:
>
> 
> On 2018年04月04日 20:53, w...@redhat.com wrote:
> >From: Wei Xu 
> >
> >This is a prototype for virtio-net 1.1 support in userspace backend,
> >only minimum part are included in this RFC(roughly synced to v8 as
> >Jason and Tiwei's RFC).
> >
> >Test has been done together with Tiwei's RFC guest virtio-net driver
> >patch, ping and a quick iperf test successfully.
> >
> >Issues:
> >1. Rx performance of Iperf is much slower than TX.
> > TX: 13-15Gb
> > RX: 100-300Mb
> 
> This needs to be investigated. What's the pps of TX/RX then? (Maybe you can
> try Jen's dpdk code too).

Yes, I haven't tune any tso/gso on tap so the pps should match the bandwidth,
will try some more debugging and tried Jen's code if I can not resolve it.

Wei

> 
> Thanks
> 
> >
> >Missing:
> >- device and driver
> >- indirect descriptor
> >- migration
> >- vIOMMU support
> >- other revisions since v8
> >- see FIXME
> >
> >Wei Xu (8):
> >   virtio: feature bit, data structure for packed ring
> >   virtio: memory cache for packed ring
> >   virtio: add empty check for packed ring
> >   virtio: add detach element for packed ring(1.1)
> >   virtio: notification tweak for packed ring
> >   virtio: flush/push support for packed ring
> >   virtio: get avail bytes check for packed ring
> >   virtio: queue pop support for packed ring
> >
> >  hw/virtio/virtio.c | 618 
> > +++--
> >  include/hw/virtio/virtio.h |  12 +-
> >  include/standard-headers/linux/virtio_config.h |   2 +
> >  3 files changed, 601 insertions(+), 31 deletions(-)
> >
> 



Re: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

2018-04-09 Thread Jason Wang



On 2018年04月04日 20:53, w...@redhat.com wrote:

From: Wei Xu 

This is a prototype for virtio-net 1.1 support in userspace backend,
only minimum part are included in this RFC(roughly synced to v8 as
Jason and Tiwei's RFC).

Test has been done together with Tiwei's RFC guest virtio-net driver
patch, ping and a quick iperf test successfully.

Issues:
1. Rx performance of Iperf is much slower than TX.
 TX: 13-15Gb
 RX: 100-300Mb


This needs to be investigated. What's the pps of TX/RX then? (Maybe you 
can try Jen's dpdk code too).


Thanks



Missing:
- device and driver
- indirect descriptor
- migration
- vIOMMU support
- other revisions since v8
- see FIXME

Wei Xu (8):
   virtio: feature bit, data structure for packed ring
   virtio: memory cache for packed ring
   virtio: add empty check for packed ring
   virtio: add detach element for packed ring(1.1)
   virtio: notification tweak for packed ring
   virtio: flush/push support for packed ring
   virtio: get avail bytes check for packed ring
   virtio: queue pop support for packed ring

  hw/virtio/virtio.c | 618 +++--
  include/hw/virtio/virtio.h |  12 +-
  include/standard-headers/linux/virtio_config.h |   2 +
  3 files changed, 601 insertions(+), 31 deletions(-)






Re: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

2018-04-04 Thread no-reply
Hi,

This series seems to have some coding style problems. See output below for
more information:

Type: series
Message-id: 1522846444-31725-1-git-send-email-w...@redhat.com
Subject: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

=== TEST SCRIPT BEGIN ===
#!/bin/bash

BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0

git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram

commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..."
if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
failed=1
echo
fi
n=$((n+1))
done

exit $failed
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
   094b62cd9c..e5efa1f5f2  master -> master
 * [new tag]   
patchew/1522846444-31725-1-git-send-email-w...@redhat.com -> 
patchew/1522846444-31725-1-git-send-email-w...@redhat.com
 t [tag update]patchew/20180329113320.8053-1-coh...@redhat.com -> 
patchew/20180329113320.8053-1-coh...@redhat.com
 t [tag update]
patchew/20180404114709.45118-1-jiangshan...@gmail.com -> 
patchew/20180404114709.45118-1-jiangshan...@gmail.com
Switched to a new branch 'test'
a5ed4f9354 virtio: queue pop support for packed ring
eda38cccfc virtio: get avail bytes check for packed ring
d6b7b8f192 virtio: flush/push support for packed ring
2ae1f234dc virtio: notification tweak for packed ring
5c44b67629 virtio: add detach element for packed ring(1.1)
7bc7372e93 virtio: add empty check for packed ring
cf399da035 virtio: memory cache for packed ring
606ec5dc23 virtio: feature bit, data structure for packed ring

=== OUTPUT BEGIN ===
Checking PATCH 1/8: virtio: feature bit, data structure for packed ring...
ERROR: open brace '{' following struct go on the same line
#21: FILE: hw/virtio/virtio.c:43:
+typedef struct VRingDescPacked
+{

ERROR: open brace '{' following struct go on the same line
#64: FILE: hw/virtio/virtio.c:104:
+typedef struct VRingPacked
+{

total: 2 errors, 0 warnings, 104 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 2/8: virtio: memory cache for packed ring...
Checking PATCH 3/8: virtio: add empty check for packed ring...
ERROR: "foo* bar" should be "foo *bar"
#40: FILE: hw/virtio/virtio.c:463:
+static inline bool is_desc_avail(struct VRingDescPacked* desc)

ERROR: return is not a function, parentheses are not required
#42: FILE: hw/virtio/virtio.c:465:
+return (!!(desc->flags & AVAIL_DESC_PACKED(1)) !=

WARNING: line over 80 characters
#77: FILE: hw/virtio/virtio.c:513:
+vring_desc_read_packed(vq->vdev, , >desc_packed, 
vq->last_avail_idx);

total: 2 errors, 1 warnings, 95 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 4/8: virtio: add detach element for packed ring(1.1)...
Checking PATCH 5/8: virtio: notification tweak for packed ring...
Checking PATCH 6/8: virtio: flush/push support for packed ring...
Checking PATCH 7/8: virtio: get avail bytes check for packed ring...
ERROR: braces {} are necessary for all arms of this statement
#125: FILE: hw/virtio/virtio.c:1056:
+} while (desc.flags & VRING_DESC_F_NEXT);
[...]

total: 1 errors, 0 warnings, 154 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

Checking PATCH 8/8: virtio: queue pop support for packed ring...
=== OUTPUT END ===

Test command exited with code: 1


---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to patchew-de...@redhat.com

Re: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

2018-04-04 Thread no-reply
Hi,

This series failed docker-mingw@fedora build test. Please find the testing 
commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.

Type: series
Message-id: 1522846444-31725-1-git-send-email-w...@redhat.com
Subject: [Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

=== TEST SCRIPT BEGIN ===
#!/bin/bash
set -e
git submodule update --init dtc
# Let docker tests dump environment info
export SHOW_ENV=1
export J=8
time make docker-test-mingw@fedora
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
Switched to a new branch 'test'
a5ed4f9354 virtio: queue pop support for packed ring
eda38cccfc virtio: get avail bytes check for packed ring
d6b7b8f192 virtio: flush/push support for packed ring
2ae1f234dc virtio: notification tweak for packed ring
5c44b67629 virtio: add detach element for packed ring(1.1)
7bc7372e93 virtio: add empty check for packed ring
cf399da035 virtio: memory cache for packed ring
606ec5dc23 virtio: feature bit, data structure for packed ring

=== OUTPUT BEGIN ===
Submodule 'dtc' (git://git.qemu-project.org/dtc.git) registered for path 'dtc'
Cloning into '/var/tmp/patchew-tester-tmp-qr0vpq45/src/dtc'...
Submodule path 'dtc': checked out 'e54388015af1fb4bf04d0bca99caba1074d9cc42'
  BUILD   fedora
make[1]: Entering directory '/var/tmp/patchew-tester-tmp-qr0vpq45/src'
  GEN 
/var/tmp/patchew-tester-tmp-qr0vpq45/src/docker-src.2018-04-04-09.11.46.2207/qemu.tar
Cloning into 
'/var/tmp/patchew-tester-tmp-qr0vpq45/src/docker-src.2018-04-04-09.11.46.2207/qemu.tar.vroot'...
done.
Checking out files:  45% (2739/6066)   
Checking out files:  46% (2791/6066)   
Checking out files:  47% (2852/6066)   
Checking out files:  48% (2912/6066)   
Checking out files:  49% (2973/6066)   
Checking out files:  50% (3033/6066)   
Checking out files:  51% (3094/6066)   
Checking out files:  52% (3155/6066)   
Checking out files:  53% (3215/6066)   
Checking out files:  54% (3276/6066)   
Checking out files:  55% (3337/6066)   
Checking out files:  56% (3397/6066)   
Checking out files:  57% (3458/6066)   
Checking out files:  58% (3519/6066)   
Checking out files:  59% (3579/6066)   
Checking out files:  60% (3640/6066)   
Checking out files:  61% (3701/6066)   
Checking out files:  62% (3761/6066)   
Checking out files:  63% (3822/6066)   
Checking out files:  64% (3883/6066)   
Checking out files:  65% (3943/6066)   
Checking out files:  66% (4004/6066)   
Checking out files:  67% (4065/6066)   
Checking out files:  68% (4125/6066)   
Checking out files:  69% (4186/6066)   
Checking out files:  70% (4247/6066)   
Checking out files:  71% (4307/6066)   
Checking out files:  72% (4368/6066)   
Checking out files:  73% (4429/6066)   
Checking out files:  74% (4489/6066)   
Checking out files:  75% (4550/6066)   
Checking out files:  76% (4611/6066)   
Checking out files:  77% (4671/6066)   
Checking out files:  78% (4732/6066)   
Checking out files:  79% (4793/6066)   
Checking out files:  80% (4853/6066)   
Checking out files:  81% (4914/6066)   
Checking out files:  82% (4975/6066)   
Checking out files:  83% (5035/6066)   
Checking out files:  84% (5096/6066)   
Checking out files:  85% (5157/6066)   
Checking out files:  86% (5217/6066)   
Checking out files:  87% (5278/6066)   
Checking out files:  88% (5339/6066)   
Checking out files:  89% (5399/6066)   
Checking out files:  90% (5460/6066)   
Checking out files:  91% (5521/6066)   
Checking out files:  92% (5581/6066)   
Checking out files:  93% (5642/6066)   
Checking out files:  94% (5703/6066)   
Checking out files:  95% (5763/6066)   
Checking out files:  96% (5824/6066)   
Checking out files:  97% (5885/6066)   
Checking out files:  98% (5945/6066)   
Checking out files:  99% (6006/6066)   
Checking out files: 100% (6066/6066)   
Checking out files: 100% (6066/6066), done.
Your branch is up-to-date with 'origin/test'.
Submodule 'dtc' (git://git.qemu-project.org/dtc.git) registered for path 'dtc'
Cloning into 
'/var/tmp/patchew-tester-tmp-qr0vpq45/src/docker-src.2018-04-04-09.11.46.2207/qemu.tar.vroot/dtc'...
Submodule path 'dtc': checked out 'e54388015af1fb4bf04d0bca99caba1074d9cc42'
Submodule 'ui/keycodemapdb' (git://git.qemu.org/keycodemapdb.git) registered 
for path 'ui/keycodemapdb'
Cloning into 
'/var/tmp/patchew-tester-tmp-qr0vpq45/src/docker-src.2018-04-04-09.11.46.2207/qemu.tar.vroot/ui/keycodemapdb'...
Submodule path 'ui/keycodemapdb': checked out 
'6b3d716e2b6472eb7189d3220552280ef3d832ce'
  COPYRUNNER
RUN test-mingw in qemu:fedora 
Packages installed:
PyYAML-3.12-5.fc27.x86_64
SDL-devel-1.2.15-29.fc27.x86_64
bc-1.07.1-3.fc27.x86_64
bison-3.0.4-8.fc27.x86_64
bzip2-1.0.6-24.fc27.x86_64
ccache-3.3.6-1.fc27.x86_64
clang-5.0.1-3.fc27.x86_64
findutils-4.6.0-16.fc27.x86_64
flex-2.6.1-5.fc27.x86_64
gcc-7.3.1-5.fc27.x86_64
gcc-c++-7.3.1-5.fc27.x86_64
gettext-0.19.8.1-12.fc27.x86_64
git-2.14.3-3.fc27.x86_64
glib2-devel-2.54.3-2.fc27.x86_64

[Qemu-devel] [RFC PATCH 0/8] virtio-net 1.1 userspace backend support

2018-04-04 Thread wexu
From: Wei Xu 

This is a prototype for virtio-net 1.1 support in userspace backend,
only minimum part are included in this RFC(roughly synced to v8 as
Jason and Tiwei's RFC).

Test has been done together with Tiwei's RFC guest virtio-net driver
patch, ping and a quick iperf test successfully.

Issues:
1. Rx performance of Iperf is much slower than TX.
TX: 13-15Gb
RX: 100-300Mb

Missing:
- device and driver
- indirect descriptor
- migration
- vIOMMU support
- other revisions since v8
- see FIXME

Wei Xu (8):
  virtio: feature bit, data structure for packed ring
  virtio: memory cache for packed ring
  virtio: add empty check for packed ring
  virtio: add detach element for packed ring(1.1)
  virtio: notification tweak for packed ring
  virtio: flush/push support for packed ring
  virtio: get avail bytes check for packed ring
  virtio: queue pop support for packed ring

 hw/virtio/virtio.c | 618 +++--
 include/hw/virtio/virtio.h |  12 +-
 include/standard-headers/linux/virtio_config.h |   2 +
 3 files changed, 601 insertions(+), 31 deletions(-)

-- 
2.7.4