From: John Hodge Date: Wed, 28 Nov 2012 04:07:34 +0000 (+0800) Subject: Kernel/x86_64 - Cleanup and pondering mboot framebuffer X-Git-Tag: rel0.15~597^2~31 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=4cf1d784cb119f1f9e9075b316ffffb6a945dc55;p=tpg%2Facess2.git Kernel/x86_64 - Cleanup and pondering mboot framebuffer --- diff --git a/KernelLand/Kernel/arch/x86_64/main.c b/KernelLand/Kernel/arch/x86_64/main.c index a855a474..f4c4a818 100644 --- a/KernelLand/Kernel/arch/x86_64/main.c +++ b/KernelLand/Kernel/arch/x86_64/main.c @@ -53,7 +53,6 @@ void kmain(Uint MbMagic, void *MbInfoPtr) // Adjust Multiboot structure address mbInfo = (void*)( (Uint)MbInfoPtr + KERNEL_BASE ); gsBootCmdLine = (char*)( (Uint)mbInfo->CommandLine + KERNEL_BASE); - // TODO: ref above? nPMemMapEnts = Multiboot_LoadMemoryMap(mbInfo, KERNEL_BASE, pmemmap, MAX_PMEMMAP_ENTS, KERNEL_LOAD, (tVAddr)&gKernelEnd - KERNEL_BASE ); @@ -87,6 +86,8 @@ void kmain(Uint MbMagic, void *MbInfoPtr) Log_Log("Arch", "Starting VFS..."); VFS_Init(); + // Multiboot_InitFramebuffer(mbInfo); + gaArch_BootModules = Multiboot_LoadModules(mbInfo, KERNEL_BASE, &giArch_NumBootModules); *(Uint16*)(KERNEL_BASE|0xB8000) = 0x1F00|'Z'; diff --git a/KernelLand/Kernel/arch/x86_64/proc.c b/KernelLand/Kernel/arch/x86_64/proc.c index 48504a8b..2a38d621 100644 --- a/KernelLand/Kernel/arch/x86_64/proc.c +++ b/KernelLand/Kernel/arch/x86_64/proc.c @@ -457,9 +457,8 @@ void Proc_ClearThread(tThread *Thread) tTID Proc_NewKThread(void (*Fcn)(void*), void *Data) { Uint rsp; - tThread *newThread, *cur; + tThread *newThread; - cur = Proc_GetCurThread(); newThread = Threads_CloneTCB(0); if(!newThread) return -1; @@ -536,11 +535,9 @@ tTID Proc_Clone(Uint Flags) */ tThread *Proc_SpawnWorker(void (*Fcn)(void*), void *Data) { - tThread *new, *cur; + tThread *new; Uint stack_contents[3]; - cur = Proc_GetCurThread(); - // Create new thread new = Threads_CloneThreadZero(); if(!new) {