diff options
author | Haixiang Bao <haixiang.bao@amlogic.com> | 2018-12-19 20:52:01 +0800 |
---|---|---|
committer | Dongjin Kim <tobetter@gmail.com> | 2019-03-05 23:25:59 +0900 |
commit | ebf62f265f0928c0cebca3f78c4cb5aa8ef138c6 (patch) | |
tree | 517d608f5d6308aea3b8256dd21236de881fb4c8 /common/cmd_imgread.c | |
parent | 6864574e3cbfc9e92b99814e3044b516d7e5e395 (diff) | |
download | u-boot-odroid-c1-ebf62f265f0928c0cebca3f78c4cb5aa8ef138c6.tar.gz |
BL33: EFUSE: use EFUSE_LICX for Riscure review [1/1]
PD#SWPL-3175
Problem:
Riscure code review report EFUSE license should use EFUSE_LICx but not
AO_SEC_SD_CFG10/9 any more
Solution:
For G12A/G12B/TL1... which have EFUSE_LICx will use them instead
of AO_SEC_SD_CFG10/9
EFUSE_LIC0/1/2/3 -> AO_SEC_SD_CFG10/9
Verify:
axg/g12a/g12b/gxb/gxl/gxtvbb/tl1/txhd/txl/txlx skt board verify on the way
Change-Id: I13979aecf4e6e58f6d3469b110b500bc83d18e25
Signed-off-by: Haixiang Bao <haixiang.bao@amlogic.com>
Diffstat (limited to 'common/cmd_imgread.c')
-rw-r--r-- | common/cmd_imgread.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/common/cmd_imgread.c b/common/cmd_imgread.c index 1bb33309fb..ebf230dce8 100644 --- a/common/cmd_imgread.c +++ b/common/cmd_imgread.c @@ -18,6 +18,8 @@ #include <asm/arch/secure_apb.h> #include <libfdt.h> +#include <amlogic/aml_efuse.h> + typedef struct andr_img_hdr boot_img_hdr; #define debugP(fmt...) //printf("[Dbg imgread]L%d:", __LINE__),printf(fmt) @@ -78,12 +80,6 @@ typedef struct{ #define COMPILE_TYPE_ASSERT(expr, t) typedef char t[(expr) ? 1 : -1] COMPILE_TYPE_ASSERT(2048 >= sizeof(AmlSecureBootImgHeader), _cc); -static int is_secure_boot_enabled(void) -{ - const unsigned long cfg10 = readl(AO_SEC_SD_CFG10); - return ( cfg10 & (0x1<< 4) ); -} - static int is_andr_9_image(void* pBuffer) { int nReturn = 0; @@ -121,7 +117,7 @@ static int _aml_get_secure_boot_kernel_size(const void* pLoadaddr, unsigned* pTo unsigned int nBlkCnt = 0; const t_aml_enc_blk* pBlkInf = NULL; unsigned char *pAndHead = (unsigned char *)pLoadaddr; - unsigned int isSecure = is_secure_boot_enabled(); + unsigned int isSecure = IS_FEAT_BOOT_VERIFY(); rc = __LINE__; |