summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2023-09-25 00:15:31 +0300
committerTom Rini <trini@konsulko.com>2023-09-25 00:15:31 +0300
commit15155ab0a3d1f839509bcac620bfb38f950bead6 (patch)
tree8e6de0f3f2c782a6a86f5538c3fbea9fc1a4d19a
parent729b0104bb9f658eb4212a1b880873eb781874de (diff)
parent62a3c66a7c1ee733695b46542c4a9034f3a663a4 (diff)
downloadu-boot-15155ab0a3d1f839509bcac620bfb38f950bead6.tar.xz
Merge tag 'u-boot-imx-20230923' of https://source.denx.de/u-boot/custodians/u-boot-imx
Fixes for 2023.10 ----------------- CI: https://source.denx.de/u-boot/custodians/u-boot-imx/-/pipelines/17831
-rw-r--r--arch/arm/dts/imx7d-colibri-eval-v3-u-boot.dtsi2
-rw-r--r--arch/arm/dts/imx7d-pico-pi-u-boot.dtsi2
-rw-r--r--arch/arm/dts/imx7d-sdb-qspi-u-boot.dtsi2
-rw-r--r--arch/arm/dts/imx7d-sdb-u-boot.dtsi2
-rw-r--r--arch/arm/dts/imx7d-smegw01-u-boot.dtsi3
-rw-r--r--arch/arm/dts/imx7s-u-boot.dtsi7
-rw-r--r--arch/arm/mach-imx/Kconfig1
-rw-r--r--arch/arm/mach-imx/hab.c8
-rw-r--r--board/storopack/smegw01/smegw01.env14
-rw-r--r--configs/smegw01_defconfig3
10 files changed, 33 insertions, 11 deletions
diff --git a/arch/arm/dts/imx7d-colibri-eval-v3-u-boot.dtsi b/arch/arm/dts/imx7d-colibri-eval-v3-u-boot.dtsi
index 52aa875870..57ca28edb7 100644
--- a/arch/arm/dts/imx7d-colibri-eval-v3-u-boot.dtsi
+++ b/arch/arm/dts/imx7d-colibri-eval-v3-u-boot.dtsi
@@ -3,6 +3,8 @@
* Copyright 2020-2022 Toradex
*/
+#include "imx7s-u-boot.dtsi"
+
&{/aliases} {
/* SDHCI instance order: eMMC, SD/MMC */
mmc0 = &usdhc3;
diff --git a/arch/arm/dts/imx7d-pico-pi-u-boot.dtsi b/arch/arm/dts/imx7d-pico-pi-u-boot.dtsi
index 67b41ae112..843b4583e5 100644
--- a/arch/arm/dts/imx7d-pico-pi-u-boot.dtsi
+++ b/arch/arm/dts/imx7d-pico-pi-u-boot.dtsi
@@ -1,3 +1,5 @@
+#include "imx7s-u-boot.dtsi"
+
/{
aliases {
mmc0 = &usdhc3;
diff --git a/arch/arm/dts/imx7d-sdb-qspi-u-boot.dtsi b/arch/arm/dts/imx7d-sdb-qspi-u-boot.dtsi
index 62cdcbaeb6..896c8bcaa5 100644
--- a/arch/arm/dts/imx7d-sdb-qspi-u-boot.dtsi
+++ b/arch/arm/dts/imx7d-sdb-qspi-u-boot.dtsi
@@ -3,6 +3,8 @@
* Copyright 2018 NXP
*/
+#include "imx7s-u-boot.dtsi"
+
&qspi {
flash0: mx25l51245g@0 {
compatible = "jedec,spi-nor";
diff --git a/arch/arm/dts/imx7d-sdb-u-boot.dtsi b/arch/arm/dts/imx7d-sdb-u-boot.dtsi
index ac1d6e2e64..e4a27b8dd5 100644
--- a/arch/arm/dts/imx7d-sdb-u-boot.dtsi
+++ b/arch/arm/dts/imx7d-sdb-u-boot.dtsi
@@ -1,3 +1,5 @@
+#include "imx7s-u-boot.dtsi"
+
&fec2 {
status = "disable";
};
diff --git a/arch/arm/dts/imx7d-smegw01-u-boot.dtsi b/arch/arm/dts/imx7d-smegw01-u-boot.dtsi
new file mode 100644
index 0000000000..90f7500ee3
--- /dev/null
+++ b/arch/arm/dts/imx7d-smegw01-u-boot.dtsi
@@ -0,0 +1,3 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+#include "imx7s-u-boot.dtsi"
diff --git a/arch/arm/dts/imx7s-u-boot.dtsi b/arch/arm/dts/imx7s-u-boot.dtsi
new file mode 100644
index 0000000000..c4c1da3c64
--- /dev/null
+++ b/arch/arm/dts/imx7s-u-boot.dtsi
@@ -0,0 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0+ OR MIT
+
+&crypto {
+ sec_jr0: jr@1000 {
+ status = "disabled";
+ };
+};
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index d94b5828d0..fda762426e 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -32,6 +32,7 @@ config IMX_RDC
config IMX_BOOTAUX
bool "Support boot auxiliary core"
depends on ARCH_MX7 || ARCH_MX6 || ARCH_VF610 || ARCH_IMX8 || ARCH_IMX8M
+ select LIB_ELF
help
bootaux [addr] to boot auxiliary core.
diff --git a/arch/arm/mach-imx/hab.c b/arch/arm/mach-imx/hab.c
index b3ef36c797..27e053ef70 100644
--- a/arch/arm/mach-imx/hab.c
+++ b/arch/arm/mach-imx/hab.c
@@ -662,7 +662,7 @@ static int do_authenticate_image_or_failover(struct cmd_tbl *cmdtp, int flag,
{
int ret = CMD_RET_FAILURE;
- if (argc != 4) {
+ if (argc < 3) {
ret = CMD_RET_USAGE;
goto error;
}
@@ -703,7 +703,7 @@ U_BOOT_CMD(
"addr length ivt_offset\n"
"addr - image hex address\n"
"length - image hex length\n"
- "ivt_offset - hex offset of IVT in the image"
+ "ivt_offset - hex offset of IVT in the image (optional)"
);
U_BOOT_CMD(
@@ -715,11 +715,11 @@ U_BOOT_CMD(
U_BOOT_CMD(
hab_auth_img_or_fail, 4, 0,
do_authenticate_image_or_failover,
- "authenticate image via HAB on failure drop to USB BootROM mode",
+ "authenticate image via HAB. Switch to USB BootROM mode on failure",
"addr length ivt_offset\n"
"addr - image hex address\n"
"length - image hex length\n"
- "ivt_offset - hex offset of IVT in the image"
+ "ivt_offset - hex offset of IVT in the image (optional)"
);
U_BOOT_CMD(
diff --git a/board/storopack/smegw01/smegw01.env b/board/storopack/smegw01/smegw01.env
index 1263ddac8e..528310dd81 100644
--- a/board/storopack/smegw01/smegw01.env
+++ b/board/storopack/smegw01/smegw01.env
@@ -48,13 +48,8 @@ commit_mmc=
saveenv;
fi;
console=ttymxc0
-fdt_addr=0x83000000
-fdtfile=imx7d-smegw01.dtb
-fit_addr=0x88000000
-image=fitImage
-loadaddr=0x80800000
loadbootpart=mmc partconf 1 boot_part
-loadimage=load mmc ${mmcdev}:${gpt_partition_entry} ${fit_addr} boot/${image}
+loadimage=load mmc ${mmcdev}:${gpt_partition_entry}
loadpart=gpt setenv mmc ${mmcdev} rootfs-${mmcpart_committed}
mmcargs=
setenv bootargs console=${console},${baudrate} root=/dev/mmcblk${mmcdev}p${gpt_partition_entry} rootwait rw SM_ROOT_DEV=${mmcdev} SM_ROOT_PART=${gpt_partition_entry} SM_BOOT_PART=${boot_part}
@@ -71,8 +66,13 @@ mmcboot=
else
run altbootcmd;
fi;
+#ifdef CONFIG_SYS_BOOT_LOCKED
+ hab_auth_img ${fileaddr} ${filesize};
+#else
+ hab_auth_img_or_fail ${fileaddr} ${filesize};
+#endif
run mmcargs;
- if bootm ${fit_addr}; then
+ if bootm; then
;
else
run altbootcmd;
diff --git a/configs/smegw01_defconfig b/configs/smegw01_defconfig
index 7f1b2bee8e..616038387e 100644
--- a/configs/smegw01_defconfig
+++ b/configs/smegw01_defconfig
@@ -14,6 +14,7 @@ CONFIG_ARMV7_BOOT_SEC_DEFAULT=y
CONFIG_IMX_RDC=y
CONFIG_IMX_BOOTAUX=y
CONFIG_IMX_HAB=y
+CONFIG_SYS_LOAD_ADDR=0x88000000
CONFIG_SYS_MEMTEST_START=0x80000000
CONFIG_SYS_MEMTEST_END=0xa0000000
CONFIG_FIT=y
@@ -54,6 +55,8 @@ CONFIG_SYS_RELOC_GD_ENV_ADDR=y
CONFIG_SYS_MMC_ENV_DEV=1
CONFIG_ENV_WRITEABLE_LIST=y
CONFIG_ENV_ACCESS_IGNORE_FORCE=y
+CONFIG_USE_BOOTFILE=y
+CONFIG_BOOTFILE="boot/fitImage"
CONFIG_NET_RANDOM_ETHADDR=y
CONFIG_BOUNCE_BUFFER=y
CONFIG_BOOTCOUNT_LIMIT=y