summaryrefslogtreecommitdiffstats
path: root/hw/pci.h
diff options
context:
space:
mode:
authorAnthony PERARD <anthony.perard@citrix.com>2012-06-21 15:35:28 +0000
committerStefano Stabellini <stefano.stabellini@eu.citrix.com>2012-06-21 16:06:10 +0000
commit7aa8cbb9211a7c93d37b79502915df5757d2fb17 (patch)
tree4e4c9e06052c27fe46550d4060a706652ab0c669 /hw/pci.h
parent396af688fcac4495d4805f319c6d05930db63fb4 (diff)
downloadhqemu-7aa8cbb9211a7c93d37b79502915df5757d2fb17.zip
hqemu-7aa8cbb9211a7c93d37b79502915df5757d2fb17.tar.gz
pci.c: Add opaque argument to pci_for_each_device.
The purpose is to have a more generic pci_for_each_device by passing an extra argument to the function called on every device. This patch will be used in a next patch. Signed-off-by: Anthony PERARD <anthony.perard@citrix.com> Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'hw/pci.h')
-rw-r--r--hw/pci.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/pci.h b/hw/pci.h
index 7f223c0..95b608c 100644
--- a/hw/pci.h
+++ b/hw/pci.h
@@ -312,7 +312,9 @@ PCIDevice *pci_nic_init(NICInfo *nd, const char *default_model,
PCIDevice *pci_nic_init_nofail(NICInfo *nd, const char *default_model,
const char *default_devaddr);
int pci_bus_num(PCIBus *s);
-void pci_for_each_device(PCIBus *bus, int bus_num, void (*fn)(PCIBus *bus, PCIDevice *d));
+void pci_for_each_device(PCIBus *bus, int bus_num,
+ void (*fn)(PCIBus *bus, PCIDevice *d, void *opaque),
+ void *opaque);
PCIBus *pci_find_root_bus(int domain);
int pci_find_domain(const PCIBus *bus);
PCIDevice *pci_find_device(PCIBus *bus, int bus_num, uint8_t devfn);
OpenPOWER on IntegriCloud