qemu-e2k/tests/libqos
Stefan Hajnoczi e77abbe98b libqos: add virtio used ring support
Existing tests do not touch the virtqueue used ring.  Instead they poll
the virtqueue ISR register and peek into their request's device-specific
status field.

It turns out that the virtqueue ISR register can be set to 1 more than
once for a single notification (see commit
83d768b564 "virtio: set ISR on dataplane
notifications").  This causes problems for tests that assume a 1:1
correspondence between the ISR being 1 and request completion.

Peeking at device-specific status fields is also problematic if the
device has no field that can be abused for EINPROGRESS polling
semantics.  This is the case if all the field's values may be set by the
device; there's no magic constant left for polling.

It's time to process the used ring for completed requests, just like a
real virtio guest driver.  This patch adds the necessary APIs.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Fam Zheng <famz@redhat.com>
Tested-by: Eric Blake <eblake@redhat.com>
Tested-by: Kevin Wolf <kwolf@redhat.com>
Message-id: 20170628184724.21378-3-stefanha@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2017-06-30 11:03:45 +01:00
..
ahci.c libqos/ahci: Add get_sense and test_ready 2016-11-14 11:15:55 -05:00
ahci.h libqos/ahci: Add get_sense and test_ready 2016-11-14 11:15:55 -05:00
fw_cfg.c
fw_cfg.h
i2c-imx.c
i2c-omap.c
i2c.c
i2c.h
libqos-pc.c
libqos-pc.h
libqos-spapr.c
libqos-spapr.h
libqos.c
libqos.h
malloc-generic.c
malloc-generic.h
malloc-pc.c
malloc-pc.h
malloc-spapr.c
malloc-spapr.h
malloc.c
malloc.h
pci-pc.c
pci-pc.h
pci-spapr.c libqos: fix spapr qpci_map() 2017-01-31 10:10:13 +11:00
pci-spapr.h
pci.c
pci.h
rtas.c
rtas.h
usb.c tests: fix usb-test leaks 2017-03-01 11:51:29 +04:00
usb.h tests: fix usb-test leaks 2017-03-01 11:51:29 +04:00
virtio-mmio.c
virtio-mmio.h
virtio-pci.c tests: fix virtio-blk-test leaks 2017-03-01 11:58:57 +04:00
virtio-pci.h tests: add specialized device_find function 2017-03-01 11:57:04 +04:00
virtio.c libqos: add virtio used ring support 2017-06-30 11:03:45 +01:00
virtio.h libqos: add virtio used ring support 2017-06-30 11:03:45 +01:00