diff options
author | Isaku Yamahata <yamahata@valinux.co.jp> | 2009-10-30 21:20:57 +0900 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-11-09 08:43:04 -0600 |
commit | 2217dcfff5e24a16217cba5e53c3579f97d8880e (patch) | |
tree | a5e05980d3e68b55c0a12c1cc24d0f821721f3b2 /hw/apb_pci.c | |
parent | e369cad7cd574d6d7e680ccd4d3227de7d1a0135 (diff) |
pci: use PCI_SLOT() and PCI_FUNC().
use PCI_SLOT() and PCI_FUNC() where appropriate instead of
direct use of bit operation.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/apb_pci.c')
-rw-r--r-- | hw/apb_pci.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/hw/apb_pci.c b/hw/apb_pci.c index 43be7ceeb5..1ea3e0dc42 100644 --- a/hw/apb_pci.c +++ b/hw/apb_pci.c @@ -261,11 +261,13 @@ PCIBus *pci_apb_init(target_phys_addr_t special_base, 0, 32); pci_create_simple(d->host_state.bus, 0, "pbm"); /* APB secondary busses */ - *bus2 = pci_bridge_init(d->host_state.bus, 8, PCI_VENDOR_ID_SUN, - PCI_DEVICE_ID_SUN_SIMBA, pci_apb_map_irq, + *bus2 = pci_bridge_init(d->host_state.bus, PCI_DEVFN(1, 0), + PCI_VENDOR_ID_SUN, PCI_DEVICE_ID_SUN_SIMBA, + pci_apb_map_irq, "Advanced PCI Bus secondary bridge 1"); - *bus3 = pci_bridge_init(d->host_state.bus, 9, PCI_VENDOR_ID_SUN, - PCI_DEVICE_ID_SUN_SIMBA, pci_apb_map_irq, + *bus3 = pci_bridge_init(d->host_state.bus, PCI_DEVFN(1, 1), + PCI_VENDOR_ID_SUN, PCI_DEVICE_ID_SUN_SIMBA, + pci_apb_map_irq, "Advanced PCI Bus secondary bridge 2"); return d->host_state.bus; |