summaryrefslogtreecommitdiffstats
path: root/tools/virtio/linux/uio.h
diff options
context:
space:
mode:
authorRusty Russell2013-03-20 04:20:24 +0100
committerRusty Russell2013-03-20 04:36:04 +0100
commit1515c5ce26ae45a8ecea4e68a484562ca4356442 (patch)
tree6d28df1c18dcff47f26f347576079a30b5badb37 /tools/virtio/linux/uio.h
parentvringh: host-side implementation of virtio rings. (diff)
downloadkernel-qcow2-linux-1515c5ce26ae45a8ecea4e68a484562ca4356442.tar.gz
kernel-qcow2-linux-1515c5ce26ae45a8ecea4e68a484562ca4356442.tar.xz
kernel-qcow2-linux-1515c5ce26ae45a8ecea4e68a484562ca4356442.zip
tools/virtio: add vring_test.
This is mainly to test the drivers/vhost/vringh.c code, but it also uses the drivers/virtio/virtio_ring.c code for the guest side. Usage for testing the basic implementation: ./vringh_test # Test with indirect descriptors ./vringh_test --indirect # Test with indirect descriptors and event indexex ./vringh_test --indirect --eventidx You can run a parallel stress test by adding --parallel to any of the above options. eg ./vringh_test --parallel: Using CPUS 0 and 3 Guest: notified 10107974, pinged 107970 Host: notified 108158, pinged 3172148 ./vringh_test --indirect --eventidx --parallel: Using CPUS 0 and 3 Guest: notified 156357, pinged 156251 Host: notified 156251, pinged 78179 Average of 50 times doing ./vringh_test --indirect --eventidx --parallel: 2.840000-3.040000(2.927292)user Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'tools/virtio/linux/uio.h')
-rw-r--r--tools/virtio/linux/uio.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/virtio/linux/uio.h b/tools/virtio/linux/uio.h
index ecbdf922b0f4..cd20f0ba3081 100644
--- a/tools/virtio/linux/uio.h
+++ b/tools/virtio/linux/uio.h
@@ -1 +1,3 @@
+#include <linux/kernel.h>
+
#include "../../../include/linux/uio.h"