
In the commit c982874e930d ("efi_loader: refactor efi_setup_loaded_image()"), setjmp-related definitions were moved to efi_loaded_image_obj in efi_loader.h. So setjmp.h is no longer refererenced in efi_api.h.
This also fixes some error when efi_api.h will be included in mkeficapsule.c.
On the other hand, a tweak will be necessary in common/main.c as some architectures have no setjmp support.
Fixes: c982874e930d ("efi_loader: refactor efi_setup_loaded_image()") Signed-off-by: AKASHI Takahiro takahiro.akashi@linaro.org --- common/main.c | 6 ++++++ include/efi_api.h | 4 ---- include/efi_loader.h | 1 + 3 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/common/main.c b/common/main.c index ae5bcdb32f8b..a41c57c26611 100644 --- a/common/main.c +++ b/common/main.c @@ -16,7 +16,13 @@ #include <init.h> #include <net.h> #include <version.h> +#ifdef CONFIG_EFI_LOADER +/* + * Unfortunately, efi_loader requires setjmp.h, but there are + * some architectures which have no support for setjmp. + */ #include <efi_loader.h> +#endif
static void run_preboot_environment_command(void) { diff --git a/include/efi_api.h b/include/efi_api.h index 18a1adf02390..e854a8b3a112 100644 --- a/include/efi_api.h +++ b/include/efi_api.h @@ -20,10 +20,6 @@ #include <charset.h> #include <pe.h>
-#ifdef CONFIG_EFI_LOADER -#include <asm/setjmp.h> -#endif - /* UEFI spec version 2.8 */ #define EFI_SPECIFICATION_VERSION (2 << 16 | 80)
diff --git a/include/efi_loader.h b/include/efi_loader.h index de1a496a9726..6994a951bc19 100644 --- a/include/efi_loader.h +++ b/include/efi_loader.h @@ -15,6 +15,7 @@ #include <efi_api.h> #include <image.h> #include <pe.h> +#include <asm/setjmp.h>
struct blk_desc;