39 #include <sys/pci_cfgspace.h>
40 #include <sys/reboot.h>
41 #include <sys/pci_cfgspace_impl.h>
42 #include <sys/mutex.h>
43
44 extern int pci_boot_debug;
45
46 /*
47 * Interface routines
48 */
49 void pci_enumerate(int);
50 void pci_setup_tree(void);
51 void pci_reprogram(void);
52 void bus_res_fini(void);
53
54 static struct modlmisc modlmisc = {
55 &mod_miscops, "PCI BIOS interface"
56 };
57
58 static struct modlinkage modlinkage = {
59 MODREV_1, (void *)&modlmisc, NULL
60 };
61
62 int
63 _init(void)
64 {
65 int err;
66
67 if ((err = mod_install(&modlinkage)) != 0)
68 return (err);
69
70 impl_bus_add_probe(pci_enumerate);
71 return (0);
72 }
73
74 int
75 _fini(void)
76 {
77 int err;
78
79 if ((err = mod_remove(&modlinkage)) != 0)
|
39 #include <sys/pci_cfgspace.h>
40 #include <sys/reboot.h>
41 #include <sys/pci_cfgspace_impl.h>
42 #include <sys/mutex.h>
43
44 extern int pci_boot_debug;
45
46 /*
47 * Interface routines
48 */
49 void pci_enumerate(int);
50 void pci_setup_tree(void);
51 void pci_reprogram(void);
52 void bus_res_fini(void);
53
54 static struct modlmisc modlmisc = {
55 &mod_miscops, "PCI BIOS interface"
56 };
57
58 static struct modlinkage modlinkage = {
59 MODREV_1, { (void *)&modlmisc, NULL }
60 };
61
62 int
63 _init(void)
64 {
65 int err;
66
67 if ((err = mod_install(&modlinkage)) != 0)
68 return (err);
69
70 impl_bus_add_probe(pci_enumerate);
71 return (0);
72 }
73
74 int
75 _fini(void)
76 {
77 int err;
78
79 if ((err = mod_remove(&modlinkage)) != 0)
|