17 lines
417 B
C
17 lines
417 B
C
#include "../Common/bootinfo.h"
|
|
#include <VM/PMM.h>
|
|
#include <Arch/DTB.h>
|
|
#include <OS/Log.h>
|
|
#include <OS/Panic.h>
|
|
|
|
void KernelMain(Bootinfo* bootinfo) {
|
|
OSLog("Kernel started.\n");
|
|
if (bootinfo->magic != BOOTINFO_MAGIC) {
|
|
OSPanic("Invalid bootinfo magic");
|
|
}
|
|
|
|
VMBootMemoryMap bootMap = {0};
|
|
bootMap.reservedCount = 0;
|
|
DTBParse(bootinfo->dtb, &bootMap);
|
|
PMMInitialize(&bootMap);
|
|
} |