init.c 499 B

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