From c92e68da38dd7892a4afd6e44383cffcc188c46f Mon Sep 17 00:00:00 2001 From: Timon Kruiper Date: Sat, 6 Aug 2022 10:14:07 +0200 Subject: [PATCH] Kernel: Rounding size of bss to be a multiple of 8 for aarch64 linker.ld This fixes a bug where the bss was not completely zeroed out. This bug showed up when running the aarch64 Kernel baremetal on a Raspberry Pi. --- Kernel/Arch/aarch64/linker.ld | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kernel/Arch/aarch64/linker.ld b/Kernel/Arch/aarch64/linker.ld index 38cbb07767..ea81f81bc5 100644 --- a/Kernel/Arch/aarch64/linker.ld +++ b/Kernel/Arch/aarch64/linker.ld @@ -78,4 +78,4 @@ SECTIONS page_tables_phys_end = .; } -size_of_bss_divided_by_8 = (end_of_bss - start_of_bss) / 8; +size_of_bss_divided_by_8 = (end_of_bss - start_of_bss + 7) / 8;