- 13 9月, 2016 1 次提交
-
-
由 Laurent Vivier 提交于
vq->avail.idx and vq->avail->ring[] are a 16bit values, so read and write them with readw()/writew() instead of readl()/writel(). To read/write a 16bit value with a 32bit accessor works fine on little-endian CPU but not on big endian CPU. [An equivalent patch for the writew() calls was also sent by Zhang Shuai <zhangshuai13@huawei.com>. --Stefan] Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Message-id: 1472330054-22607-1-git-send-email-lvivier@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
- 20 6月, 2016 4 次提交
-
-
由 Stefan Hajnoczi 提交于
qvirtqueue_setup() allocates the vring and virtqueue state. So far there has been no function to free it. Callers have been using guest_free() for the vring but forgot to free the QVirtQueue state. This patch solves the memory leak by introducing qvirtqueue_cleanup(). Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Stefan Hajnoczi 提交于
The descriptor element, used, and avail vring structs are defined in virtio_ring.h. There is no need to duplicate them in libqos virtio. Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1462798061-30382-6-git-send-email-stefanha@redhat.com
-
由 Stefan Hajnoczi 提交于
Note that virtio_ring.h defines feature bits using their bit number: #define VIRTIO_RING_F_INDIRECT_DESC 28 On the other hand libqos virtio.h uses the bit mask: #define QVIRTIO_F_RING_INDIRECT_DESC 0x10000000 The patch makes the necessary adjustments. I have used "1u << BITMASK" instead of "1ULL << BITMASK" because the 64-bit feature fields are not implemented in libqos virtio. Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1462798061-30382-5-git-send-email-stefanha@redhat.com
-
由 Stefan Hajnoczi 提交于
Note that VIRTIO_F_ANY_LAYOUT and VIRTIO_F_NOTIFY_ON_EMPTY are bit numbers in virtio_config.h but bit masks in qtest virtio.h. Therefore it's necessary to change users from X to (1u << X). Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1462798061-30382-4-git-send-email-stefanha@redhat.com
-
- 07 6月, 2016 1 次提交
-
-
由 Peter Maydell 提交于
Remove glib.h includes, as it is provided by osdep.h. This commit was created with scripts/clean-includes. Signed-off-by: NPeter Maydell <peter.maydell@linaro.org> Reviewed-by: NEric Blake <eblake@redhat.com> Tested-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
- 16 2月, 2016 1 次提交
-
-
由 Peter Maydell 提交于
Clean up includes so that osdep.h is included first and headers which it implies are not included manually. This commit was created with scripts/clean-includes. Signed-off-by: NPeter Maydell <peter.maydell@linaro.org> Reviewed-by: NEric Blake <eblake@redhat.com> Tested-by: NEric Blake <eblake@redhat.com>
-
- 10 3月, 2015 1 次提交
-
-
由 Marc Marí 提交于
Convert use of pointers in functions of virtio to uint64_t in order to make it platform-independent. Add casting from pointers (in PCI functions) to uint64_t and vice versa through uintptr_t. Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1424812915-25728-2-git-send-email-marc.mari.barcelo@gmail.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 30 9月, 2014 2 次提交
-
-
由 Stefan Hajnoczi 提交于
Some hosts are slow or overloaded so test execution takes a long time. Test cases use timeouts to protect against an infinite loop stalling the test forever (especially important in automated test setups). Commit 6cd14054 ("libqos virtio: Increase ISR timeout") increased the clock_step() value in an attempt to lengthen the virtio interrupt wait timeout, but timeout failures are still occuring on the Travis automated testing platform. This is because clock_step() only affects the guest's virtual time. Virtio requests can be bottlenecked on host disk I/O latency - which cannot be improved by stepping the clock, so the fix was ineffective. This patch changes the qvirtio_wait_queue_isr() and qvirtio_wait_config_isr() timeout mechanism from loop iterations to microseconds. This way the test case can specify an absolute 30 second timeout. Number of loop iterations is not a reliable timeout mechanism since the speed depends on many factors including host performance. Tests should no longer timeout on overloaded Travis instances. Cc: Marc Marí <marc.mari.barcelo@gmail.com> Reported-by: NPeter Maydell <peter.maydell@linaro.org> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Stefan Hajnoczi 提交于
The virtio event_index feature lets the device driver tell the device how many requests to process before raising the next interrupt. virtio-blk-test.c tries to verify that the device does not raise an interrupt unnecessarily. Unfortunately the test has a race condition. It spins checking for an interrupt up to 100 times and then assumes the request has finished. On a slow host the I/O request could still be in flight and the test would fail. This patch waits for the request to complete, or until a 30-second timeout is reached. If an interrupt is raised while waiting the test fails since the device was not supposed to raise interrupts. Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
- 12 9月, 2014 1 次提交
-
-
由 Marc Marí 提交于
Increase the clock step to avoid Travis failure in some builds due to overagressive timeout. Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Message-id: 1410428416-5046-1-git-send-email-marc.mari.barcelo@gmail.com Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
- 08 9月, 2014 5 次提交
-
-
由 Marc Marí 提交于
Added avail_event and NO_NOTIFY check before notifying. Added used_event setting. Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Marc Marí 提交于
Added MSI-X support for qtest PCI. Added MSI-X support for virtio-pci. Added MSI-X test case in virtio-blk-test. Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Marc Marí 提交于
Add functions necessary for working with indirect descriptors. Add test using new functions. Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Marc Marí 提交于
Add status changing and feature negotiation. Add basic virtqueue support for adding and sending virtqueue requests. Add ISR checking. [Squashed request endianness fix by Greg Kurz <gkurz@linux.vnet.ibm.com> --Stefan] Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Marc Marí 提交于
Add functions to read and write virtio header fields. Add status bit setting in virtio-blk-device. Signed-off-by: NMarc Marí <marc.mari.barcelo@gmail.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-