init.c 473 B

123456789101112131415161718192021222324
  1. #include <linux/pci.h>
  2. #include <linux/init.h>
  3. #include "pci.h"
  4. /* arch_initcall has too random ordering, so call the initializers
  5. in the right sequence from here. */
  6. static __init int pci_access_init(void)
  7. {
  8. #ifdef CONFIG_PCI_MMCONFIG
  9. pci_mmcfg_init();
  10. #endif
  11. if (raw_pci_ops)
  12. return 0;
  13. #ifdef CONFIG_PCI_BIOS
  14. pci_pcbios_init();
  15. #endif
  16. if (raw_pci_ops)
  17. return 0;
  18. #ifdef CONFIG_PCI_DIRECT
  19. pci_direct_init();
  20. #endif
  21. return 0;
  22. }
  23. arch_initcall(pci_access_init);