X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Kernel%2Farch%2Fx86_64%2Fmain.c;h=af231eeaa342466859bcdffe0d2e0d28af30ccf2;hb=5255c9f07cb2e0e43cf283e256c964eaa7970c8e;hp=f2a92298d4588997f6edd179afbbe5a22b2749d4;hpb=7d7952eb5cab57587c50a9c0d8c1bc45c55c0f2c;p=tpg%2Facess2.git diff --git a/Kernel/arch/x86_64/main.c b/Kernel/arch/x86_64/main.c index f2a92298..af231eea 100644 --- a/Kernel/arch/x86_64/main.c +++ b/Kernel/arch/x86_64/main.c @@ -3,18 +3,20 @@ */ #include #include +#include // === IMPORTS === extern void Desctab_Init(void); extern void MM_InitVirt(void); extern void Heap_Install(void); extern void Threads_Init(void); -//extern void Time_Setup(void); +extern int Time_Setup(void); extern void System_Init(char *Commandline); extern void MM_InitPhys_Multiboot(tMBoot_Info *MBoot); // === PROTOTYPES === +void kmain(Uint MbMagic, void *MbInfoPtr); // === GLOBALS == char *gsBootCmdLine = NULL; @@ -35,7 +37,8 @@ void kmain(Uint MbMagic, void *MbInfoPtr) case MULTIBOOT_MAGIC: // Adjust Multiboot structure address mbInfo = (void*)( (Uint)MbInfoPtr + KERNEL_BASE ); - gsBootCmdLine = (char*)(mbInfo->CommandLine + KERNEL_BASE); + gsBootCmdLine = (char*)( (Uint)mbInfo->CommandLine + KERNEL_BASE); + Log("gsBootCmdLine = '%s'", gsBootCmdLine); MM_InitPhys_Multiboot( mbInfo ); // Set up physical memory manager break; @@ -45,6 +48,8 @@ void kmain(Uint MbMagic, void *MbInfoPtr) return ; } + Log("gsBootCmdLine = '%s'", gsBootCmdLine); + *(Uint16*)(0xB8000) = 0x1F00|'D'; Heap_Install(); @@ -52,7 +57,7 @@ void kmain(Uint MbMagic, void *MbInfoPtr) Log_Log("Arch", "Starting threading..."); Threads_Init(); - //Time_Setup(); + Time_Setup(); *(Uint16*)(0xB8000) = 0x1F00|'F'; Log_Log("Arch", "Starting VFS..."); @@ -78,7 +83,7 @@ void Arch_LoadBootModules(void) } -void StartupPrint(char *String) +void StartupPrint(const char *String) { }