- 16 6月, 2016 1 次提交
-
-
由 Michael S. Tsirkin 提交于
Add ringtest based unit test for ptr ring. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
- 23 5月, 2016 2 次提交
-
-
由 Michael S. Tsirkin 提交于
just a stub pointer for now. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
skips ring accesses but drops out of order support Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 02 3月, 2016 1 次提交
-
-
由 Andy Lutomirski 提交于
virtio_ring currently sends the device (usually a hypervisor) physical addresses of its I/O buffers. This is okay when DMA addresses and physical addresses are the same thing, but this isn't always the case. For example, this never works on Xen guests, and it is likely to fail if a physical "virtio" device ever ends up behind an IOMMU or swiotlb. The immediate use case for me is to enable virtio on Xen guests. For that to work, we need vring to support DMA address translation as well as a corresponding change to virtio_pci or to another driver. Signed-off-by: NAndy Lutomirski <luto@kernel.org> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 26 1月, 2016 2 次提交
-
-
由 Michael S. Tsirkin 提交于
This adds micro-benchmarks useful for tuning virtio ring layouts. Three layouts are currently implemented: - virtio 0.9 compatible one - an experimental extension bypassing the ring index, polling ring itself instead - an experimental extension bypassing avail and used ring completely Typical use: sh run-on-all.sh perf stat -r 10 --log-fd 1 -- ./ring It doesn't depend on the kernel directly, but it's handy to have as much virtio stuff as possible in one tree. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Fix build after API changes. Reported-by: NKamal Mostafa <kamal@canonical.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 07 12月, 2015 2 次提交
-
-
由 Michael S. Tsirkin 提交于
commit cf561f0d ("virtio: introduce virtio_is_little_endian() helper") changed byteswap logic to skip feature bit checks for LE platforms, but didn't update tools/virtio, so vring_bench started failing. Update the copy under tools/virtio/ (TODO: find a way to avoid this code duplication). Cc: Greg Kurz <gkurz@linux.vnet.ibm.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Makes them more generally available. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 16 9月, 2015 1 次提交
-
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 10 9月, 2015 1 次提交
-
-
由 Michael S. Tsirkin 提交于
more stubs, mostly Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 16 12月, 2014 6 次提交
-
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Seems to mostly be a positive. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Missed one place where vringh_test used long to pass features. Fix it up to u64. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Include missing virtio_config.h Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
As usual, add more stubs to fix test build after main codebase changes. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 09 12月, 2014 2 次提交
-
-
由 Michael S. Tsirkin 提交于
Change u32 to u64, and use BIT_ULL and 1ULL everywhere. Note: transports are unchanged, and only set low 32 bit. This guarantees that no transport sets e.g. VERSION_1 by mistake without proper support. Based on patch by Rusty. Signed-off-by: NRusty Russell <rusty@rustcorp.com.au> Signed-off-by: NCornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com> Reviewed-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
It seemed like a good idea to use bitmap for features in struct virtio_device, but it's actually a pain, and seems to become even more painful when we get more than 32 feature bits. Just change it to a u32 for now. Based on patch by Rusty. Suggested-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au> Signed-off-by: NCornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
- 02 5月, 2014 2 次提交
-
-
由 Borislav Petkov 提交于
Combine all definitions into a common tools/include/linux/types.h and kill the wild growth elsewhere. Move DECLARE_BITMAP to its proper bitmap.h header. Signed-off-by: NBorislav Petkov <bp@suse.de> Acked-by: NRusty Russell <rusty@rustcorp.com.au> Link: http://lkml.kernel.org/n/tip-azczs7qcv6h9xek9od10hiv2@git.kernel.orgSigned-off-by: NJiri Olsa <jolsa@kernel.org>
-
由 Borislav Petkov 提交于
So tools/ has been growing three, at a different stage of their development export.h headers and so we should unite into one. Add tools/include/ to the include path of virtio and liblockdep to pick the shared header now. Signed-off-by: NBorislav Petkov <bp@suse.de> Acked-by: NRusty Russell <rusty@rustcorp.com.au> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Michael S. Tsirkin <mst@redhat.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: virtio-dev@lists.oasis-open.org Cc: virtualization@lists.linux-foundation.org Link: http://lkml.kernel.org/r/1397493185-19521-2-git-send-email-bp@alien8.deSigned-off-by: NJiri Olsa <jolsa@kernel.org>
-
- 13 3月, 2014 3 次提交
-
-
由 Joel Stanley 提交于
Fixes the following build failure: cc -g -O2 -Wall -I. -I ../../usr/include/ -Wno-pointer-sign -fno-strict-overflow -fno-strict-aliasing -fno-common -MMD -U_FORTIFY_SOURCE -c -o virtio_test.o virtio_test.c virtio_test.c: In function ‘run_test’: virtio_test.c:176:7: error: expected ‘)’ before ‘r’ r = -1; ^ Fixes: 53c18c99 (virtio_test: verify if virtqueue_kick() succeeded) Cc: Heinz Graalfs <graalfs@linux.vnet.ibm.com> Signed-off-by: NJoel Stanley <joel@jms.id.au> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Joel Stanley 提交于
In commit bb478d8b virtio_ring: plug kmemleak false positive, kmemleak_ignore was introduced. This broke compilation of virtio_test: cc -g -O2 -Wall -I. -I ../../usr/include/ -Wno-pointer-sign -fno-strict-overflow -fno-strict-aliasing -fno-common -MMD -U_FORTIFY_SOURCE -c -o virtio_ring.o ../../drivers/virtio/virtio_ring.c ../../drivers/virtio/virtio_ring.c: In function ‘vring_add_indirect’: ../../drivers/virtio/virtio_ring.c:177:2: warning: implicit declaration of function ‘kmemleak_ignore’ [-Wimplicit-function-declaration] kmemleak_ignore(desc); ^ cc virtio_test.o virtio_ring.o -o virtio_test virtio_ring.o: In function `vring_add_indirect': tools/virtio/../../drivers/virtio/virtio_ring.c:177: undefined reference to `kmemleak_ignore' Add a dummy header for tools/virtio, and add #incldue <linux/kmemleak.h> to drivers/virtio/virtio_ring.c so it is picked up by the userspace tools. Signed-off-by: NJoel Stanley <joel@jms.id.au> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Joel Stanley 提交于
The virtio headers have changed recently: 5b1bf7cb virtio_ring: let virtqueue_{kick()/notify()} return a bool 46f9c2b9 virtio_ring: change host notification API Update the internal copies to fix the build of virtio_test: cc -g -O2 -Wall -I. -I ../../usr/include/ -Wno-pointer-sign -fno-strict-overflow -fno-strict-aliasing -fno-common -MMD -U_FORTIFY_SOURCE -c -o virtio_test.o virtio_test.c In file included from virtio_test.c:15:0: ./linux/virtio.h:76:19: error: conflicting types for ‘vring_new_virtqueue’ struct virtqueue *vring_new_virtqueue(unsigned int index, ^ In file included from ./linux/virtio_ring.h:1:0, from ../../usr/include/linux/vhost.h:17, from virtio_test.c:14: ./linux/../../../include/linux/virtio_ring.h:68:19: note: previous declaration of ‘vring_new_virtqueue’ was here struct virtqueue *vring_new_virtqueue(unsigned int index, virtio_test.c: In function ‘vq_info_add’: virtio_test.c:103:12: warning: passing argument 7 of ‘vring_new_virtqueue’ from incompatible pointer type [enabled by default] vq_notify, vq_callback, "test"); ^ In file included from virtio_test.c:15:0: ./linux/virtio.h:76:19: note: expected ‘void (*)(struct virtqueue *)’ but argument is of type ‘_Bool (*)(struct virtqueue *)’ struct virtqueue *vring_new_virtqueue(unsigned int index, ^ Signed-off-by: NJoel Stanley <joel@jms.id.au> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 29 10月, 2013 2 次提交
-
-
由 Heinz Graalfs 提交于
Verify if a host kick succeeded by checking return value of virtqueue_kick(). Signed-off-by: NHeinz Graalfs <graalfs@linux.vnet.ibm.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Heinz Graalfs 提交于
Currently a host kick error is silently ignored and not reflected in the virtqueue of a particular virtio device. Changing the notify API for guest->host notification seems to be one prerequisite in order to be able to handle such errors in the context where the kick is triggered. This patch changes the notify API. The notify function must return a bool return value. It returns false if the host notification failed. Signed-off-by: NHeinz Graalfs <graalfs@linux.vnet.ibm.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 15 7月, 2013 1 次提交
-
-
由 Ramkumar Ramachandra 提交于
Signed-off-by: NRamkumar Ramachandra <artagnon@gmail.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 09 7月, 2013 1 次提交
-
-
由 Michael S. Tsirkin 提交于
This fixes build for the vringh test: [linux]$ make -C tools/virtio/ make: Entering directory `/home/mst/scm/linux/tools/virtio' cc -g -O2 -Wall -I. -I ../../usr/include/ -Wno-pointer-sign -fno-strict-overflow -fno-strict-aliasing -fno-common -MMD -U_FORTIFY_SOURCE -c -o vringh.o ../../drivers/vhost/vringh.c ../../drivers/vhost/vringh.c:1010:16: error: expected declaration specifiers or ‘...’ before string constant Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 20 3月, 2013 6 次提交
-
-
由 Rusty Russell 提交于
Make the rest of the paths use virtqueue_add_sgs or add_outbuf. Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Rusty Russell 提交于
As expected, the simplified accessors are faster. for i in `seq 50`; do /usr/bin/time -f 'Wall time:%e' ./vringh_test --indirect --eventidx --parallel --fast-vringh; done 2>&1 | stats --trim-outliers: Before: Using CPUS 0 and 3 Guest: notified 0, pinged 39062-39063(39063) Host: notified 39062-39063(39063), pinged 0 Wall time:1.760000-2.220000(1.789167) After: Using CPUS 0 and 3 Guest: notified 0, pinged 39037-39063(39062) Host: notified 39037-39063(39062), pinged 0 Wall time:1.640000-1.810000(1.676875) Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Rusty Russell 提交于
virtio_scsi can really use this, to avoid the current hack of copying the whole sg array. Some other things get slightly neater, too. This causes a slowdown in virtqueue_add_buf(), which is implemented as a wrapper. This is addressed in the next patches. for i in `seq 50`; do /usr/bin/time -f 'Wall time:%e' ./vringh_test --indirect --eventidx --parallel --fast-vringh; done 2>&1 | stats --trim-outliers: Before: Using CPUS 0 and 3 Guest: notified 0, pinged 39009-39063(39062) Host: notified 39009-39063(39062), pinged 0 Wall time:1.700000-1.950000(1.723542) After: Using CPUS 0 and 3 Guest: notified 0, pinged 39062-39063(39063) Host: notified 39062-39063(39063), pinged 0 Wall time:1.760000-2.220000(1.789167) Signed-off-by: NRusty Russell <rusty@rustcorp.com.au> Reviewed-by: NWanlong Gao <gaowanlong@cn.fujitsu.com> Reviewed-by: NAsias He <asias@redhat.com>
-
由 Rusty Russell 提交于
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: NRusty Russell <rusty@rustcorp.com.au>
-
由 Rusty Russell 提交于
This makes them a bit more like the kernel headers, so we can include more real kernel headers in our tests. In addition this means that we don't break tools/virtio with the next patch. Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 18 12月, 2012 1 次提交
-
-
由 Rusty Russell 提交于
We simplified virtqueue_add_buf(), make it clear in the callers. Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 06 12月, 2012 1 次提交
-
-
由 Cong Ding 提交于
We do not allow old-style function definition. Always spell foo(void) if a function does not take any parameters. Signed-off-by: NCong Ding <dinggnu@gmail.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 28 9月, 2012 2 次提交
-
-
由 Yoshihiro YUNOMAE 提交于
pthread flag should not be -lpthread but -pthread using gcc. The -lpthread links the external multithread library. On the other hand, the -pthread manages both the gcc's preprocessor and linker to be able to compile with pthread. Signed-off-by: NYoshihiro YUNOMAE <yoshihiro.yunomae.ez@hitachi.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
由 Yoshihiro YUNOMAE 提交于
This patch adds a user tool, "trace agent" for sending trace data of a guest to a Host in low overhead. This agent has the following functions: - splice a page of ring-buffer to read_pipe without memory copying - splice the page from write_pipe to virtio-console without memory copying - write trace data to stdout by using -o option - controlled by start/stop orders from a Host Changes in v2: - Cleanup (change fprintf() to pr_err() and an include guard) Signed-off-by: NYoshihiro YUNOMAE <yoshihiro.yunomae.ez@hitachi.com> Acked-by: NAmit Shah <amit.shah@redhat.com> Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
-
- 02 5月, 2012 1 次提交
-
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 28 2月, 2012 2 次提交
-
-
由 Michael S. Tsirkin 提交于
The tool should never use them, abort if it does. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Make tool build after virtio changes broke it. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-