aboutsummaryrefslogtreecommitdiff
path: root/tests/libqos/virtio-pci.h
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2017-02-07 16:53:11 +0400
committerMarc-André Lureau <marcandre.lureau@redhat.com>2017-03-01 11:57:04 +0400
commitc4523aae0664aecaa366d45e3d0f3d810ca33062 (patch)
tree77087986532cc18a45ea04ed66b995cc3f52f74b /tests/libqos/virtio-pci.h
parent62030ed135e4cfb960cb626510cbb3ea77bb9ef9 (diff)
tests: add specialized device_find function
Allow specifying which slot to look for the device. This will be used in the following patch to avoid leaking when multiple devices exists and we want to lookup the hotplug one. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'tests/libqos/virtio-pci.h')
-rw-r--r--tests/libqos/virtio-pci.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/libqos/virtio-pci.h b/tests/libqos/virtio-pci.h
index 0fab916cf8..6ef19094cb 100644
--- a/tests/libqos/virtio-pci.h
+++ b/tests/libqos/virtio-pci.h
@@ -31,9 +31,9 @@ typedef struct QVirtQueuePCI {
extern const QVirtioBus qvirtio_pci;
-void qvirtio_pci_foreach(QPCIBus *bus, uint16_t device_type,
- void (*func)(QVirtioDevice *d, void *data), void *data);
QVirtioPCIDevice *qvirtio_pci_device_find(QPCIBus *bus, uint16_t device_type);
+QVirtioPCIDevice *qvirtio_pci_device_find_slot(QPCIBus *bus,
+ uint16_t device_type, int slot);
void qvirtio_pci_device_free(QVirtioPCIDevice *dev);
void qvirtio_pci_device_enable(QVirtioPCIDevice *d);