diff options
| author | Aleksa Vuckovic <aleksav013@gmail.com> | 2022-07-31 03:55:45 +0200 |
|---|---|---|
| committer | Aleksa Vuckovic <aleksav013@gmail.com> | 2022-08-02 19:39:04 +0200 |
| commit | 132510156e1b907498dd83724f12ca101ae32f88 (patch) | |
| tree | e91a8b79fd3f090db0523fc78f308d81652693e8 /kernel/boot64.S | |
long mode multiboot2
Diffstat (limited to 'kernel/boot64.S')
| -rw-r--r-- | kernel/boot64.S | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/kernel/boot64.S b/kernel/boot64.S new file mode 100644 index 0000000..e46bbef --- /dev/null +++ b/kernel/boot64.S @@ -0,0 +1,17 @@ +.global begin_long_mode + +.section .text +.code64 + +begin_long_mode: + + // reload segment registers + mov $0, %eax + mov %eax, %ss + mov %eax, %ds + mov %eax, %es + mov %eax, %fs + mov %eax, %gs + + call main + hlt |
