]> git.baikalelectronics.ru Git - uboot.git/commitdiff
board: apalis-imx8: initialize snvs
authorAndrejs Cainikovs <andrejs.cainikovs@toradex.com>
Mon, 16 Jan 2023 19:05:12 +0000 (20:05 +0100)
committerStefano Babic <sbabic@denx.de>
Mon, 30 Jan 2023 20:02:27 +0000 (21:02 +0100)
Initialize Secure Non-Volatile Storage, aka SNVS.

Signed-off-by: Andrejs Cainikovs <andrejs.cainikovs@toradex.com>
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Fabio Estevam <festevam@denx.de>
board/toradex/apalis-imx8/apalis-imx8.c

index ad0986eebfc1c9d7eb8002b276973d183b5a289c..6b43b58700734e2d37da857baac42b41250f37b1 100644 (file)
@@ -12,6 +12,7 @@
 #include <asm/arch/imx8-pins.h>
 #include <asm/arch/iomux.h>
 #include <asm/arch/sci/sci.h>
+#include <asm/arch/snvs_security_sc.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/gpio.h>
 #include <asm/io.h>
@@ -290,6 +291,13 @@ int board_init(void)
 {
        board_gpio_init();
 
+       if (IS_ENABLED(CONFIG_IMX_SNVS_SEC_SC_AUTO)) {
+               int ret = snvs_security_sc_init();
+
+               if (ret)
+                       return ret;
+       }
+
        return 0;
 }