From e9383335b44d7fb3926f14d99d1fab5fad3e8a89 Mon Sep 17 00:00:00 2001 From: mintsuki Date: Wed, 22 Dec 2021 20:27:51 +0100 Subject: [PATCH] stivale1&2: Allocate kernel with the right memmap type for 32-bit --- stage23/protos/stivale.c | 2 +- stage23/protos/stivale2.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stage23/protos/stivale.c b/stage23/protos/stivale.c index 0f93ab4f..30cf8706 100644 --- a/stage23/protos/stivale.c +++ b/stage23/protos/stivale.c @@ -153,7 +153,7 @@ bool stivale_load(char *config, char *cmdline) { } case 32: { if (!loaded_by_anchor) { - if (elf32_load(kernel, (uint32_t *)&entry_point, NULL, 10)) + if (elf32_load(kernel, (uint32_t *)&entry_point, NULL, STIVALE_MMAP_KERNEL_AND_MODULES)) panic(true, "stivale: ELF32 load failure"); ret = elf32_load_section(kernel, &stivale_hdr, ".stivalehdr", diff --git a/stage23/protos/stivale2.c b/stage23/protos/stivale2.c index 7f8758af..13d8853e 100644 --- a/stage23/protos/stivale2.c +++ b/stage23/protos/stivale2.c @@ -201,7 +201,7 @@ bool stivale2_load(char *config, char *cmdline) { } case 32: { if (!loaded_by_anchor) { - if (elf32_load(kernel, (uint32_t *)&entry_point, NULL, 10)) + if (elf32_load(kernel, (uint32_t *)&entry_point, NULL, STIVALE2_MMAP_KERNEL_AND_MODULES)) panic(true, "stivale2: ELF32 load failure"); ret = elf32_load_section(kernel, &stivale2_hdr, ".stivale2hdr",