diff options
author | Ahmad Fatoum <a.fatoum@pengutronix.de> | 2021-11-22 09:47:24 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2021-12-13 23:19:38 +0100 |
commit | 774d4f87c31e2c8f7ac141660b21bd5ede93a117 (patch) | |
tree | 0b864e0730495a150f449d08178f4290e1c0d624 | |
parent | 5ed75dd721a3312c286b01814514cb225fb464dc (diff) | |
download | barebox-774d4f87c31e2c8f7ac141660b21bd5ede93a117.tar.gz barebox-774d4f87c31e2c8f7ac141660b21bd5ede93a117.tar.xz |
efi: make efi_main __noreturn
The function never returns, so mark it as such.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Link: https://lore.barebox.org/20211122084732.2597109-23-a.fatoum@pengutronix.de
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
-rw-r--r-- | common/efi/payload/init.c | 6 | ||||
-rw-r--r-- | include/efi.h | 2 |
2 files changed, 3 insertions, 5 deletions
diff --git a/common/efi/payload/init.c b/common/efi/payload/init.c index e1f968117a..d8a43e8885 100644 --- a/common/efi/payload/init.c +++ b/common/efi/payload/init.c @@ -221,12 +221,10 @@ static int efi_init(void) } device_initcall(efi_init); -asmlinkage efi_status_t efi_main(efi_handle_t, efi_system_table_t *); - /** * efi-main - Entry point for EFI images */ -efi_status_t efi_main(efi_handle_t image, efi_system_table_t *sys_table) +void efi_main(efi_handle_t image, efi_system_table_t *sys_table) { efi_physical_addr_t mem; size_t memsize; @@ -266,8 +264,6 @@ efi_status_t efi_main(efi_handle_t image, efi_system_table_t *sys_table) mem_malloc_init((void *)mem, (void *)mem + memsize - 1); start_barebox(); - - return EFI_SUCCESS; } static int efi_core_init(void) diff --git a/include/efi.h b/include/efi.h index 36452d296d..51382f5bfe 100644 --- a/include/efi.h +++ b/include/efi.h @@ -591,6 +591,8 @@ efi_guidcmp (efi_guid_t left, efi_guid_t right) return memcmp(&left, &right, sizeof (efi_guid_t)); } +__attribute__((noreturn)) void efi_main(efi_handle_t, efi_system_table_t *); + /* * Variable Attributes */ |