From 4f551f54c4fac000c7e04037c1d3a9e39e882a45 Mon Sep 17 00:00:00 2001 From: Idan Horowitz Date: Mon, 3 Jan 2022 20:45:05 +0200 Subject: [PATCH] Kernel: Align GDT to the size of a Descriptor This is not actually required by the specification, but it means we will take the aligned fast-path in QEMU. --- Kernel/Arch/x86/Processor.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kernel/Arch/x86/Processor.h b/Kernel/Arch/x86/Processor.h index e49b34cb3c..f1946ebd46 100644 --- a/Kernel/Arch/x86/Processor.h +++ b/Kernel/Arch/x86/Processor.h @@ -68,7 +68,7 @@ class Processor { #endif DescriptorTablePointer m_gdtr; - Descriptor m_gdt[256]; + alignas(Descriptor) Descriptor m_gdt[256]; u32 m_gdt_length; u32 m_cpu;