From fe116c65f56184d728c999a15b2c4123175c7120 Mon Sep 17 00:00:00 2001 From: Victor Chong Date: Thu, 14 Sep 2017 01:27:19 +0900 Subject: hikey*: Undef BL32_BASE when building without SPD Otherwise, BL2 tries to load a BL32 image and triggers assert(result == 0) in plat_get_image_source() in hikey{960}_io_storage.c in a debug build, or displays ERROR: BL2: Failed to load image in a release build. Signed-off-by: Victor Chong --- plat/hisilicon/hikey/include/platform_def.h | 7 +++++++ plat/hisilicon/hikey960/include/platform_def.h | 7 +++++++ 2 files changed, 14 insertions(+) (limited to 'plat') diff --git a/plat/hisilicon/hikey/include/platform_def.h b/plat/hisilicon/hikey/include/platform_def.h index 0c736ab1..01806542 100644 --- a/plat/hisilicon/hikey/include/platform_def.h +++ b/plat/hisilicon/hikey/include/platform_def.h @@ -135,6 +135,13 @@ #error "Currently unsupported HIKEY_TSP_LOCATION_ID value" #endif +/* BL32 is mandatory in AArch32 */ +#ifndef AARCH32 +#ifdef SPD_none +#undef BL32_BASE +#endif /* SPD_none */ +#endif + #define NS_BL1U_BASE (BL2_BASE) #define NS_BL1U_SIZE (0x00010000) #define NS_BL1U_LIMIT (NS_BL1U_BASE + NS_BL1U_SIZE) diff --git a/plat/hisilicon/hikey960/include/platform_def.h b/plat/hisilicon/hikey960/include/platform_def.h index 2fae666b..202952c5 100644 --- a/plat/hisilicon/hikey960/include/platform_def.h +++ b/plat/hisilicon/hikey960/include/platform_def.h @@ -94,6 +94,13 @@ #error "Currently unsupported HIKEY960_TSP_LOCATION_ID value" #endif +/* BL32 is mandatory in AArch32 */ +#ifndef AARCH32 +#ifdef SPD_none +#undef BL32_BASE +#endif /* SPD_none */ +#endif + #define NS_BL1U_BASE (BL31_LIMIT) /* 1AC9_8000 */ #define NS_BL1U_SIZE (0x00100000) #define NS_BL1U_LIMIT (NS_BL1U_BASE + NS_BL1U_SIZE) -- cgit v1.2.3