mirror of
https://git.stationery.faith/corn/corn.git
synced 2024-11-22 00:12:18 +00:00
added amd64 shim
This commit is contained in:
parent
4aad3cce1d
commit
e4fc6902b7
3 changed files with 7 additions and 2 deletions
|
@ -1,5 +1,6 @@
|
||||||
global start
|
global start
|
||||||
extern kmain
|
extern kmain
|
||||||
|
extern amd64_shim
|
||||||
bits 32
|
bits 32
|
||||||
|
|
||||||
; base, limit, access, flags
|
; base, limit, access, flags
|
||||||
|
@ -62,8 +63,8 @@ after_lgdt:
|
||||||
mov gs, ax
|
mov gs, ax
|
||||||
mov esp, stack_end
|
mov esp, stack_end
|
||||||
mov ebp, stack_end
|
mov ebp, stack_end
|
||||||
sti
|
|
||||||
push ebx
|
push ebx
|
||||||
|
call amd64_shim
|
||||||
call kmain
|
call kmain
|
||||||
cli
|
cli
|
||||||
halt:
|
halt:
|
||||||
|
|
4
src/arch/amd64/shim.c
Normal file
4
src/arch/amd64/shim.c
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
// entry point for amd64
|
||||||
|
void amd64_shim(void *boot_info) {
|
||||||
|
|
||||||
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
void kmain(void *boot_info) {
|
void kmain() {
|
||||||
while(1) {
|
while(1) {
|
||||||
asm("cli; hlt");
|
asm("cli; hlt");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue