[PATCH] common: PBL_OPTEE: Allow to compile in THUMB2 mode

Sascha Hauer s.hauer at pengutronix.de
Mon Jun 30 01:01:22 PDT 2025


OP-TEE gained support for jumping back to the normal world in THUMB2
mode in commit 3d80ccc97 ("core: Allow non-secure context restore in
thumb mode"). The first OP-TEE release with this commit is 3.11.0. Allow
to compile barebox in THUMB2 mode with PBL_OPTEE enabled and update the
help text.

Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 common/Kconfig | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/common/Kconfig b/common/Kconfig
index 39a597bb70..0651f955dc 100644
--- a/common/Kconfig
+++ b/common/Kconfig
@@ -1408,15 +1408,15 @@ config BOOTM_OPTEE
 config PBL_OPTEE
 	bool "Enable OP-TEE early start"
 	depends on ARM
-	depends on !THUMB2_BAREBOX
 	select HAVE_OPTEE
 	help
 	  Allows starting OP-TEE during lowlevel initialization of the PBL.
 	  Requires explicit support in the board's lowlevel file (for ARM32)
 	  or the generic SoC support (for ARM64).
 
-	  The trampoline for jumping back from OP-TEE to barebox does currently
-	  not handle THUMB2, so barebox must be built either for A32 or A64.
+	  OP-TEE versions older than 3.11.0 do not support jumping back from OP-TEE
+	  to barebox in THUMB2 mode. Make sure you do not compile barebox in THUMB2
+	  mode for OP-TEE versions older than this.
 
 config FILETYPE_STRINGS
 	bool "Print file types as strings"
-- 
2.39.5




More information about the barebox mailing list