From a15857ea2847cd8550c9b7414883cd1b8d4da782 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 17 May 2019 18:20:11 +0200 Subject: [PATCH] Kernel: Clear the X86 direction flag (DF) in the boot loader. I'm not sure who is responsible for clearing this, but IIUC the C++ ABI expects it to be clear on function entry, so just to be on the safe side.. --- Kernel/Boot/boot.S | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Kernel/Boot/boot.S b/Kernel/Boot/boot.S index 694d53f9f1..0fa21e34dc 100644 --- a/Kernel/Boot/boot.S +++ b/Kernel/Boot/boot.S @@ -40,6 +40,9 @@ stack_top: .type init, @function start: + cli + cld + mov $stack_top, %esp and $-16, %esp @@ -48,7 +51,6 @@ start: pushl %eax /* Multiboot header magic */ pushl %ebx /* Multiboot header pointer */ - cli call init pushl $exit_message