blob: d7fc3e0d78c85b20c5724df8be600bce8b032913 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#include <stdbool.h>
#include <serial.h>
#include <printf.h>
#include <paging.h>
#include <video.h>
#include <acpi.h>
void panic() { // will fill with debugging info latter
printf("Kernel panic!\n");
for(;;);
}
void main() {
if(!(init_serial(COM1))) {
printf("\nKernal started on CPU 1!\n"); // will detect cpu later
}
rsdp_t *rsdp;
rsdp = find_RSDP();
if(!(rsdp)) {
printf("Couldn't find the RSDP... not sure what to do now.\n");
panic();
}
dump_video();
debug_print_memory();
init_memory();
panic();
}
|