From 92ad44ce3af9b000146d324e5c0f5dfce16927f9 Mon Sep 17 00:00:00 2001 From: Dennis Kobert Date: Fri, 25 Oct 2019 03:59:21 +0200 Subject: Start 64bit mode --- kernel/src/long_mode_init.asm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 kernel/src/long_mode_init.asm (limited to 'kernel/src/long_mode_init.asm') diff --git a/kernel/src/long_mode_init.asm b/kernel/src/long_mode_init.asm new file mode 100644 index 0000000..f105388 --- /dev/null +++ b/kernel/src/long_mode_init.asm @@ -0,0 +1,17 @@ +global long_mode_start + +section .text +bits 64 +long_mode_start: + ; load 0 into all data segment registers + mov ax, 0 + mov ss, ax + mov ds, ax + mov es, ax + mov fs, ax + mov gs, ax + + ; print `Uff!` to screen + mov rax, 0x8521846683668255 + mov qword [0xb8000], rax + hlt -- cgit v1.2.3-70-g09d2