Commit 18a2add4 authored by David Mosberger's avatar David Mosberger

ia64: Reorganize initialization sequence a bit.

parent edc56689
...@@ -49,9 +49,6 @@ extern void ia64_mca_check_errors( void ); ...@@ -49,9 +49,6 @@ extern void ia64_mca_check_errors( void );
struct pci_fixup pcibios_fixups[1]; struct pci_fixup pcibios_fixups[1];
struct pci_ops *pci_root_ops;
/* /*
* Low-level SAL-based PCI configuration access functions. Note that SAL * Low-level SAL-based PCI configuration access functions. Note that SAL
* calls are already serialized (via sal_lock), so we don't need another * calls are already serialized (via sal_lock), so we don't need another
...@@ -106,13 +103,10 @@ struct pci_ops pci_sal_ops = { ...@@ -106,13 +103,10 @@ struct pci_ops pci_sal_ops = {
.write = pci_sal_write, .write = pci_sal_write,
}; };
struct pci_ops *pci_root_ops = &pci_sal_ops; /* default to SAL */
/*
* Initialization. Uses the SAL interface
*/
struct pci_bus * struct pci_bus *
pcibios_scan_root(int bus) pcibios_scan_root (int bus)
{ {
struct list_head *list = NULL; struct list_head *list = NULL;
struct pci_bus *pci_bus = NULL; struct pci_bus *pci_bus = NULL;
...@@ -127,35 +121,21 @@ pcibios_scan_root(int bus) ...@@ -127,35 +121,21 @@ pcibios_scan_root(int bus)
} }
printk("PCI: Probing PCI hardware on bus (%02x)\n", bus); printk("PCI: Probing PCI hardware on bus (%02x)\n", bus);
return pci_scan_bus(bus, pci_root_ops, NULL); return pci_scan_bus(bus, pci_root_ops, NULL);
} }
void __init
pcibios_config_init (void)
{
if (pci_root_ops)
return;
printk("PCI: Using SAL to access configuration space\n");
pci_root_ops = &pci_sal_ops;
return;
}
static int __init static int __init
pcibios_init (void) pcibios_init (void)
{ {
# define PCI_BUSES_TO_SCAN 255 # define PCI_BUSES_TO_SCAN 255
int i = 0; int i = 0;
acpi_init(); /* hackedy hack hack... */
#ifdef CONFIG_IA64_MCA #ifdef CONFIG_IA64_MCA
ia64_mca_check_errors(); /* For post-failure MCA error logging */ ia64_mca_check_errors(); /* For post-failure MCA error logging */
#endif #endif
pcibios_config_init();
platform_pci_fixup(0); /* phase 0 fixups (before buses scanned) */ platform_pci_fixup(0); /* phase 0 fixups (before buses scanned) */
printk("PCI: Probing PCI hardware\n"); printk("PCI: Probing PCI hardware\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment