]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
rockchip: rk3308: Enable ARMv8 crypto and FIT checksum validation
authorJonas Karlman <jonas@kwiboo.se>
Mon, 8 Apr 2024 18:14:00 +0000 (18:14 +0000)
committerKever Yang <kever.yang@rock-chips.com>
Fri, 26 Apr 2024 07:47:03 +0000 (15:47 +0800)
The RK3308 SoC support ARMv8 Cryptography Extensions and use of the
ARMv8 crypto extensions help speed up FIT checksum validation in SPL.

Imply ARMV8_SET_SMPEN and ARMV8_CRYPTO to take advantage of the crypto
extensions for SHA256 when validating checksum of FIT images.

Imply SPL_FIT_SIGNATURE and LEGACY_IMAGE_FORMAT to enable FIT checksum
validation on all RK3308 boards.

Also disable CONFIG_SPL_RAW_IMAGE_SUPPORT in board defconfigs to ensure
SPL does not try to jump to code that failed checksum validation.

Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
arch/arm/mach-rockchip/Kconfig
configs/evb-rk3308_defconfig
configs/roc-cc-rk3308_defconfig
configs/rock-pi-s-rk3308_defconfig

index 4a77f181021a04799e9da82cfe8843fe670eff24..0902eb285453536172485f3e3c2a878595036587 100644 (file)
@@ -160,8 +160,12 @@ config ROCKCHIP_RK3308
        select SPL_ATF
        select SPL_ATF_NO_PLATFORM_PARAM
        select SPL_LOAD_FIT
+       imply ARMV8_CRYPTO
+       imply ARMV8_SET_SMPEN
+       imply LEGACY_IMAGE_FORMAT
        imply ROCKCHIP_COMMON_BOARD
        imply SPL_CLK
+       imply SPL_FIT_SIGNATURE
        imply SPL_RAM
        imply SPL_REGMAP
        imply SPL_ROCKCHIP_COMMON_BOARD
index d57b2f6b8e55677d9ea89312f06402415e41b3c7..6a6d2540317dfac33af431c9d6d9472a3a35b1db 100644 (file)
@@ -20,6 +20,7 @@ CONFIG_SYS_CONSOLE_INFO_QUIET=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x20000
 CONFIG_SPL_PAD_TO=0x7f8000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_CMD_BDI is not set
 # CONFIG_CMD_CONSOLE is not set
 # CONFIG_CMD_ELF is not set
index 5e8f51ec01e33b39e6f2bfe3443dcea2cb720be0..2f4a160acc24214fbe4bafd75663457f15c2b3fc 100644 (file)
@@ -20,6 +20,7 @@ CONFIG_SYS_CONSOLE_INFO_QUIET=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x20000
 CONFIG_SPL_PAD_TO=0x7f8000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_CMD_BDI is not set
 # CONFIG_CMD_CONSOLE is not set
 # CONFIG_CMD_ELF is not set
index 1e9cd2c0fc7e3b4b884aaba0da20bff6f2520c86..b0ad4d6ce35490703323dd4d84f3800a9060759b 100644 (file)
@@ -21,6 +21,7 @@ CONFIG_SYS_CONSOLE_INFO_QUIET=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x20000
 CONFIG_SPL_PAD_TO=0x7f8000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_CMD_BDI is not set
 # CONFIG_CMD_CONSOLE is not set
 # CONFIG_CMD_ELF is not set