arm/optee: disable clang due to breakage
PATCH 1/1 arm/optee: disable clang due to breakage
With clang 18, optee-os no longer compiles cleanly. It is now seeing:
| In file included from core/arch/arm/kernel/vfp.c:6:
| In file included from core/arch/arm/include/arm.h:131:
| core/arch/arm/include/arm64.h:436:1: error: expected readable system
register
| 436 | DEFINE_U32_REG_READWRITE_FUNCS(fpcr)
| | ^
| core/arch/arm/include/arm64.h:417:3: note: expanded from macro
'DEFINE_U32_REG_READWRITE_FUNCS'
| 417 | DEFINE_U32_REG_READ_FUNC(reg) \
| | ^
| core/arch/arm/include/arm64.h:411:3: note: expanded from macro
'DEFINE_U32_REG_READ_FUNC'
| 411 | DEFINE_REG_READ_FUNC_(reg, uint32_t, reg)
| | ^
| core/arch/arm/include/arm64.h:398:15: note: expanded from macro
'DEFINE_REG_READ_FUNC_'
| 398 | asm volatile("mrs %0, " #asmreg : "=r" (val64));
\
| | ^
| <inline asm>:1:10: note: instantiated into assembly here
| 1 | mrs x8, fpcr
| | ^Issues are also seen on optee-examples and optee-test. Forcing GCC for all optee recipes until this issue can be resolved.
Signed-off-by Jon Mason <[email protected]>
--- meta-arm/recipes-security/optee/optee.inc | 3 +++ 1 file changed, 3 insertions(+)
meta-arm/recipes-security/optee/optee.inc +3 -0
@@ -15,6 +15,9 @@ OPTEE_ARCH:arm = "arm32" OPTEE_ARCH:aarch64 = "arm64" OPTEE_CORE = "${@d.getVar('OPTEE_ARCH').upper()}" +# FIXME - breaks with Clang 18. See https://github.com/OP-TEE/optee_os/issues/6754 +TOOLCHAIN = "gcc" + OPTEE_TOOLCHAIN = "${@d.getVar('TOOLCHAIN') or 'gcc'}" OPTEE_COMPILER = "${@bb.utils.contains("BBFILE_COLLECTIONS", "clang-layer", "${OPTEE_TOOLCHAIN}", "gcc", d)}"
Signature · 1 line
2.39.3 (Apple Git-146)
Jon Mason
AppliedQuoted 25 lines · Jon Mason
With clang 18, optee-os no longer compiles cleanly. It is now seeing:
| In file included from core/arch/arm/kernel/vfp.c:6: | In file included from core/arch/arm/include/arm.h:131: | core/arch/arm/include/arm64.h:436:1: error: expected readable system register | 436 | DEFINE_U32_REG_READWRITE_FUNCS(fpcr) | | ^ | core/arch/arm/include/arm64.h:417:3: note: expanded from macro 'DEFINE_U32_REG_READWRITE_FUNCS' | 417 | DEFINE_U32_REG_READ_FUNC(reg) \ | | ^ | core/arch/arm/include/arm64.h:411:3: note: expanded from macro 'DEFINE_U32_REG_READ_FUNC' | 411 | DEFINE_REG_READ_FUNC_(reg, uint32_t, reg) | | ^ | core/arch/arm/include/arm64.h:398:15: note: expanded from macro 'DEFINE_REG_READ_FUNC_' | 398 | asm volatile("mrs %0, " #asmreg : "=r" (val64)); \ | | ^ | <inline asm>:1:10: note: instantiated into assembly here | 1 | mrs x8, fpcr | | ^
Quoted 1 line
[...]
Applied, thanks!
[1/1] arm/optee: disable clang due to breakage
commit: 67901eb5cbb774f5eac69374ee75b6dddac893c6
Best regards,
Signature · 1 line
Jon Mason <[email protected]>