summaryrefslogtreecommitdiff
path: root/hw/pci_internals.h
diff options
context:
space:
mode:
authorIsaku Yamahata <yamahata@valinux.co.jp>2011-01-27 15:56:35 +0900
committerMichael S. Tsirkin <mst@redhat.com>2011-03-28 18:34:22 +0200
commit90a20dbb2837f5ff05a9b19659ba1aa218cbd2de (patch)
tree35fafbfb2cfa89d26c54b3c0ca9c26cbc96005e9 /hw/pci_internals.h
parentf64622c401d4975a56b8559e16286231a1d2cfb8 (diff)
downloadqemu-90a20dbb2837f5ff05a9b19659ba1aa218cbd2de.tar.gz
qemu-90a20dbb2837f5ff05a9b19659ba1aa218cbd2de.tar.bz2
qemu-90a20dbb2837f5ff05a9b19659ba1aa218cbd2de.zip
pci: replace the magic, 256, for the maximum of devfn
Introduce symbol PCI_SLOT_MAX for the # of slots, and replace the magic, 256. 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.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/pci_internals.h b/hw/pci_internals.h
index e3c93a3cc5..efaefcded8 100644
--- a/hw/pci_internals.h
+++ b/hw/pci_internals.h
@@ -22,7 +22,7 @@ struct PCIBus {
pci_hotplug_fn hotplug;
DeviceState *hotplug_qdev;
void *irq_opaque;
- PCIDevice *devices[256];
+ PCIDevice *devices[PCI_SLOT_MAX * PCI_FUNC_MAX];
PCIDevice *parent_dev;
target_phys_addr_t mem_base;