From 38a128611157229aa8b4c0eb9a844aa178ae142a Mon Sep 17 00:00:00 2001 From: Asami Doi Date: Thu, 22 Aug 2019 11:15:12 +0900 Subject: lib: hardwaremain: Call exception_init() as soon as possible Call exception_init() before calling cbmem_initialize() because ARMv8 on QEMU uses an exception handler to detect a ram size. Signed-off-by: Asami Doi Change-Id: If010234a6576414e7e174c075b599a4aa4c19eab Reviewed-on: https://review.coreboot.org/c/coreboot/+/35022 Tested-by: build bot (Jenkins) Reviewed-by: Raul Rangel Reviewed-by: Julius Werner Reviewed-by: Furquan Shaikh --- src/lib/hardwaremain.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/lib') diff --git a/src/lib/hardwaremain.c b/src/lib/hardwaremain.c index 3c6fb931d8..a4c154e7a8 100644 --- a/src/lib/hardwaremain.c +++ b/src/lib/hardwaremain.c @@ -451,9 +451,10 @@ void main(void) /* console_init() MUST PRECEDE ALL printk()! Additionally, ensure * it is the very first thing done in ramstage.*/ console_init(); - post_code(POST_CONSOLE_READY); + exception_init(); + /* * CBMEM needs to be recovered because timestamps, ACPI, etc rely on * the cbmem infrastructure being around. Explicitly recover it. @@ -470,8 +471,6 @@ void main(void) #if CONFIG(HAVE_ACPI_RESUME) acpi_is_wakeup(); #endif - - exception_init(); threads_initialize(); /* Schedule the static boot state entries. */ -- cgit v1.2.3