Rev 4399 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 4399 | Rev 4667 | ||
|---|---|---|---|
| Line 1... | Line 1... | ||
| 1 | #include <stdio.h> |
1 | #include <stdio.h> |
| 2 | #include <stdlib.h> |
2 | #include <stdlib.h> |
| 3 | 3 | ||
| - | 4 | #include "intel_piix3.h" |
|
| 4 | #include "pci.h" |
5 | #include "pci.h" |
| 5 | #include "pci_bus.h" |
6 | #include "pci_bus.h" |
| - | 7 | #include "isa.h" |
|
| - | 8 | #include "serial.h" |
|
| - | 9 | ||
| 6 | 10 | ||
| 7 | int main(int argc, char **argv) |
11 | int main(int argc, char **argv) |
| 8 | { |
12 | { |
| 9 | printf("PCI bus driver\n"); |
13 | printf("PCI bus driver\n"); |
| 10 | 14 | ||
| 11 | if (!pci_bus_init()) { |
15 | if (!pci_bus_init()) { |
| 12 | printf("PCI bus initialization failed.\n"); |
16 | printf("PCI bus initialization failed.\n"); |
| 13 | return 1; |
17 | return 1; |
| 14 | } |
18 | } |
| 15 | 19 | ||
| - | 20 | if (!isa_bus_init()) { |
|
| - | 21 | printf("ISA bus initialization failed.\n"); |
|
| - | 22 | return 1; |
|
| - | 23 | } |
|
| - | 24 | ||
| - | 25 | ||
| - | 26 | // pci-to-isa bridge device |
|
| - | 27 | intel_piix3_init(); |
|
| - | 28 | ||
| 16 | // TODO: write driver of some device and initialize it here |
29 | // TODO: write driver of some device (serial port) and initialize it here |
| - | 30 | serial_init(); |
|
| 17 | 31 | ||
| 18 | return 0; |
32 | return 0; |
| 19 | } |
33 | } |