Activate OP-TEE driver for trusted and optee defconfig.
This driver allows detection of TEE presence for boot from flash;
CONFIG_STM32MP1_OPTEE is also removed.
Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
endchoice
-config STM32MP1_OPTEE
- bool "Support trusted boot with TF-A and OP-TEE"
- depends on TFABOOT
- default n
- help
- Say Y here to enable boot with TF-A and OP-TEE
- Trusted boot chain is :
- BootRom => TF-A.stm32 (clock & DDR) => OP-TEE => U-Boot.stm32
- OP-TEE monitor provides ST SMC to access to secure resources
-
config SYS_TEXT_BASE
default 0xC0100000
#include <common.h>
#include <fdt_support.h>
+#include <tee.h>
#include <asm/arch/sys_proto.h>
#include <dt-bindings/pinctrl/stm32-pinfunc.h>
#include <linux/io.h>
"st,package", pkg, false);
}
- if (!CONFIG_IS_ENABLED(STM32MP1_OPTEE))
+ if (!CONFIG_IS_ENABLED(OPTEE) ||
+ !tee_find_device(NULL, NULL, NULL, NULL))
stm32_fdt_disable_optee(blob);
return ret;
const char *fdt_compat;
int fdt_compat_len;
- if (IS_ENABLED(CONFIG_STM32MP1_OPTEE))
- mode = "trusted with OP-TEE";
- else if (IS_ENABLED(CONFIG_TFABOOT))
+ if (IS_ENABLED(CONFIG_TFABOOT))
mode = "trusted";
else
mode = "basic";
#include <env_internal.h>
#include <mtd.h>
#include <mtd_node.h>
+#include <tee.h>
#define MTDPARTS_LEN 256
#define MTDIDS_LEN 128
strncat(mtdparts, ",", MTDPARTS_LEN);
}
- if (CONFIG_IS_ENABLED(STM32MP1_OPTEE) && tee) {
+ if (tee) {
strncat(mtdparts, tee, MTDPARTS_LEN);
strncat(mtdparts, ",", MTDPARTS_LEN);
}
return;
}
- if (CONFIG_IS_ENABLED(STM32MP1_OPTEE))
+ if (CONFIG_IS_ENABLED(OPTEE) &&
+ tee_find_device(NULL, NULL, NULL, NULL))
tee = true;
memset(parts, 0, sizeof(parts));
const char *fdt_compat;
int fdt_compat_len;
- if (IS_ENABLED(CONFIG_STM32MP1_OPTEE))
- mode = "trusted with OP-TEE";
- else if (IS_ENABLED(TFABOOT))
+ if (IS_ENABLED(CONFIG_TFABOOT))
mode = "trusted";
else
mode = "basic";
CONFIG_ENV_OFFSET=0x280000
CONFIG_ENV_SECT_SIZE=0x40000
CONFIG_TARGET_ST_STM32MP15x=y
-CONFIG_STM32MP1_OPTEE=y
CONFIG_ENV_OFFSET_REDUND=0x2C0000
CONFIG_DISTRO_DEFAULTS=y
CONFIG_FIT=y
CONFIG_DM_SPI=y
CONFIG_STM32_QSPI=y
CONFIG_STM32_SPI=y
+CONFIG_TEE=y
+CONFIG_OPTEE=y
+# CONFIG_OPTEE_TA_AVB is not set
CONFIG_USB=y
CONFIG_DM_USB=y
CONFIG_DM_USB_GADGET=y
CONFIG_DM_SPI=y
CONFIG_STM32_QSPI=y
CONFIG_STM32_SPI=y
+CONFIG_TEE=y
+CONFIG_OPTEE=y
+# CONFIG_OPTEE_TA_AVB is not set
CONFIG_USB=y
CONFIG_DM_USB=y
CONFIG_DM_USB_GADGET=y