aboutsummaryrefslogtreecommitdiff
path: root/hw/pci_internals.h
diff options
context:
space:
mode:
authorIsaku Yamahata <yamahata@valinux.co.jp>2010-07-13 13:01:42 +0900
committerMichael S. Tsirkin <mst@redhat.com>2010-09-07 20:01:27 +0300
commit68f799944b72387c0ef9535612a212a5ea492059 (patch)
tree06be7d56583e07a9b7a3cc3db0d0f54b4332a142 /hw/pci_internals.h
parent51a92333f8eb6d0fe685544f20ad56fc9af702f5 (diff)
pci_bridge: introduce pci bridge library.
introduce pci bridge library. convert apb bridge and dec p2p bridge to use new pci bridge library. save/restore is supported as a side effect. This is also preparation for pci express root/upstream/downstream port. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/pci_internals.h')
-rw-r--r--hw/pci_internals.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/hw/pci_internals.h b/hw/pci_internals.h
index fa844abee1..e3c93a3cc5 100644
--- a/hw/pci_internals.h
+++ b/hw/pci_internals.h
@@ -5,6 +5,11 @@
* This header files is private to pci.c and pci_bridge.c
* So following structures are opaque to others and shouldn't be
* accessed.
+ *
+ * For pci-to-pci bridge needs to include this header file to embed
+ * PCIBridge in its structure or to get sizeof(PCIBridge),
+ * However, they shouldn't access those following members directly.
+ * Use accessor function in pci.h, pci_bridge.h
*/
extern struct BusInfo pci_bus_info;
@@ -30,11 +35,13 @@ struct PCIBus {
int *irq_count;
};
-typedef struct {
+struct PCIBridge {
PCIDevice dev;
+
+ /* private member */
PCIBus sec_bus;
- uint32_t vid;
- uint32_t did;
-} PCIBridge;
+ pci_map_irq_fn map_irq;
+ const char *bus_name;
+};
#endif /* QEMU_PCI_INTERNALS_H */