[U-Boot] [PATCH] armv8: lx2160ardb: Add TFABOOT Secure Boot support
Vinitha V Pillai
vinitha.pillai at nxp.com
Fri Nov 9 04:07:25 UTC 2018
Signed-off-by: Vinitha V Pillai <vinitha.pillai at nxp.com>
---
configs/lx2160ardb_tfa_SECURE_BOOT_defconfig | 83 ++++++++++++++++++++
include/configs/lx2160a_common.h | 12 ++-
2 files changed, 93 insertions(+), 2 deletions(-)
create mode 100644 configs/lx2160ardb_tfa_SECURE_BOOT_defconfig
diff --git a/configs/lx2160ardb_tfa_SECURE_BOOT_defconfig b/configs/lx2160ardb_tfa_SECURE_BOOT_defconfig
new file mode 100644
index 0000000000..eb1632866b
--- /dev/null
+++ b/configs/lx2160ardb_tfa_SECURE_BOOT_defconfig
@@ -0,0 +1,83 @@
+CONFIG_ARM=y
+CONFIG_TARGET_LX2160ARDB=y
+CONFIG_SYS_TEXT_BASE=0x82000000
+CONFIG_SEC_FIRMWARE_ARMV8_PSCI=y
+CONFIG_SECURE_BOOT=y
+CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT=y
+CONFIG_DEFAULT_DEVICE_TREE="fsl-lx2160a-rdb"
+CONFIG_NR_DRAM_BANKS=3
+CONFIG_BOOTDELAY=0
+CONFIG_DM=y
+CONFIG_FIT=y
+CONFIG_FIT_VERBOSE=y
+CONFIG_OF_BOARD_SETUP=y
+CONFIG_OF_STDOUT_VIA_ALIAS=y
+CONFIG_TFABOOT=y
+CONFIG_USE_BOOTARGS=y
+CONFIG_BOOTARGS="console=ttyAMA0,115200 root=/dev/ram0 earlycon=pl011,mmio32,0x21c0000 ramdisk_size=0x2000000 default_hugepagesz=1024m hugepagesz=1024m hugepages=2 pci=pcie_bus_perf"
+# CONFIG_CMD_IMLS is not set
+CONFIG_CMD_GREPENV=y
+CONFIG_CMD_EEPROM=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_I2C=y
+CONFIG_CMD_MMC=y
+CONFIG_CMD_SF=y
+CONFIG_CMD_USB=y
+CONFIG_CMD_CACHE=y
+CONFIG_MP=y
+CONFIG_OF_CONTROL=y
+CONFIG_ENV_IS_NOWHERE=y
+CONFIG_NET_RANDOM_ETHADDR=y
+CONFIG_DM_SERIAL=y
+CONFIG_SERIAL_PROBE_ALL=y
+CONFIG_CONS_INDEX=0
+CONFIG_FSL_CAAM=y
+CONFIG_FSL_ESDHC=y
+CONFIG_SPI=y
+CONFIG_DM_SPI=y
+CONFIG_DM_SPI_FLASH=y
+CONFIG_SPI_FLASH=y
+CONFIG_SPI_FLASH_STMICRO=y
+CONFIG_SPI_FLASH_MICRON=y
+CONFIG_SPI_FLASH_USE_4K_SECTORS=n
+CONFIG_SPI_FLASH_SPANSION=y
+CONFIG_NXP_FSPI=y
+CONFIG_FSPI_AHB_EN_4BYTE=y
+CONFIG_SYS_FSPI_AHB_INIT=y
+CONFIG_PHYLIB=y
+CONFIG_NETDEVICES=y
+CONFIG_PHY_GIGE=y
+CONFIG_CMD_NET=y
+CONFIG_CMD_PING=y
+CONFIG_CMD_PXE=y
+CONFIG_CMD_MII=y
+CONFIG_CMD_DHCP=y
+CONFIG_CMD_FAT=y
+CONFIG_CMD_EXT2=y
+CONFIG_NET=y
+CONFIG_DM_MMC=y
+CONFIG_DM_MMC_OPS=n
+CONFIG_BLK=n
+CONFIG_USB=y
+CONFIG_DM_USB=y
+CONFIG_USB_XHCI_HCD=y
+CONFIG_USB_XHCI_DWC3=y
+CONFIG_USB_STORAGE=y
+CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_SCSI_AHCI=y
+CONFIG_SCSI=y
+# CONFIG_SYS_FSL_DDR_PHY is not set
+CONFIG_SYS_GEN2_DDR_PHY=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x6000
+CONFIG_PHYLIB_10G=y
+CONFIG_PHY_AQUANTIA=y
+CONFIG_PHY_CORTINA=y
+CONFIG_PHY_ATHEROS=y
+CONFIG_PHY_INPHI=y
+CONFIG_INPHI_25G=y
+CONFIG_HUSH_PARSER=y
+CONFIG_EMC2305=y
+CONFIG_RSA=y
+CONFIG_SPL_RSA=y
+CONFIG_RSA_SOFTWARE_EXP=y
diff --git a/include/configs/lx2160a_common.h b/include/configs/lx2160a_common.h
index 51037d321a..42429ce16b 100644
--- a/include/configs/lx2160a_common.h
+++ b/include/configs/lx2160a_common.h
@@ -194,9 +194,15 @@ unsigned long get_board_ddr_clk(void);
#define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */
/* Initial environment variables */
-#define XSPI_NOR_BOOTCOMMAND "fsl_mc apply dpl 0x20d00000;" \
+#define XSPI_NOR_BOOTCOMMAND "env exists mcinitcmd && env exists secureboot" \
+ "&& esbc_validate 0x207C0000; " \
+ "env exists mcinitcmd && " \
+ "fsl_mc apply dpl 0x20d00000;" \
"sf probe 0:0;" \
"sf read 0xa0000000 0x1000000 0x3000000;" \
+ "env exists secureboot &&" \
+ "sf read 0x80200000 0x800000 0x4000 &&" \
+ "esbc_validate 0x80200000;" \
"bootm 0xa0000000"
#define SD_BOOTCOMMAND "mmc read 0xa0000000 0x6800 0xA0;" \
@@ -205,11 +211,13 @@ unsigned long get_board_ddr_clk(void);
"bootm 0xb0000000"
#define XSPI_MC_INIT_CMD \
+ "echo trying to load mc....;env exists secureboot && " \
+ "esbc_validate 0x20700000 && " \
+ "esbc_validate 0x20780000 ;" \
"fsl_mc start mc 0x20a00000 0x20e00000\0"
#define SD_MC_INIT_CMD \
"mmc read 0x80000000 0x5000 0x800;" \
"mmc read 0x80100000 0x7000 0x800;" \
"fsl_mc start mc 0x80000000 0x80100000\0"
-
#endif /* __LX2_COMMON_H */
--
2.17.1
More information about the U-Boot
mailing list