Updated mm_phys to use Debug statements instead of Log()
[tpg/acess2.git] / Kernel / arch / x86_64 / start64.asm
index 699c793..04bac26 100644 (file)
@@ -2,6 +2,12 @@
 ; Acess2 x86_64 Port
 ;
 [bits 64]
 ; Acess2 x86_64 Port
 ;
 [bits 64]
+KERNEL_BASE    equ     0xFFFF800000000000
+
+[extern kmain]
+
+[extern gMultibootPtr]
+[extern gMultibootMagic]
 
 [section .text]
 [global start64]
 
 [section .text]
 [global start64]
@@ -28,6 +34,10 @@ start64:
        mov rsp, gInitialKernelStack
        
        ; Call main
        mov rsp, gInitialKernelStack
        
        ; Call main
+       mov edi, [gMultibootMagic - KERNEL_BASE]
+       mov esi, [gMultibootPtr - KERNEL_BASE]
+       call kmain
+       
        cli
 .hlt:
        hlt
        cli
 .hlt:
        hlt
@@ -117,6 +127,6 @@ User_Syscall_Exit:
 
 [section .bss]
 [global gInitialKernelStack]
 
 [section .bss]
 [global gInitialKernelStack]
-       resd    1024*1  ; 1 Page
+       resd    1024*4  ; 4 Pages
 gInitialKernelStack:
 
 gInitialKernelStack:
 

UCC git Repository :: git.ucc.asn.au