+ tMBoot_Info *mbInfo;
+
+ LogF("Acess2 x86_65 v"EXPAND_STR(KERNEL_VERSION)"\n");
+ LogF(" Build %i, Git Hash %s\n", BUILD_NUM, gsGitHash);
+
+ Desctab_Init();
+
+ MM_InitVirt();
+ *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'C';
+
+ switch(MbMagic)
+ {
+ // Multiboot 1
+ case MULTIBOOT_MAGIC:
+ // Adjust Multiboot structure address
+ mbInfo = (void*)( (Uint)MbInfoPtr + KERNEL_BASE );
+ gsBootCmdLine = (char*)( (Uint)mbInfo->CommandLine + KERNEL_BASE);
+ Log("gsBootCmdLine = '%s'", gsBootCmdLine);
+
+ MM_InitPhys_Multiboot( mbInfo ); // Set up physical memory manager
+ break;
+ default:
+ Panic("Multiboot magic invalid %08x, expected %08x\n",
+ MbMagic, MULTIBOOT_MAGIC);
+ return ;
+ }
+
+ Log("gsBootCmdLine = '%s'", gsBootCmdLine);
+
+ *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'D';
+ Heap_Install();
+
+ *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'E';
+ Log_Log("Arch", "Starting threading...");
+ Threads_Init();
+
+ Time_Setup();
+ *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'F';
+
+ Log_Log("Arch", "Starting VFS...");
+ // Load Virtual Filesystem
+ VFS_Init();
+
+ *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'Z';
+
+ // Pass on to Independent Loader
+ Log_Log("Arch", "Starting system");
+ System_Init(gsBootCmdLine);