Hello,
I would like to run optee-os on an imx7d SoM on an Colibri Evaluation board. I try to build the `tdx-reference-minimal-image` with yocto linux 4.0 kirkstone.
In my local.conf i added the following lines:
MACHINE_FEATURES:append = " optee"
DISTRO_FEATURES:append = " optee"
IMAGE_INSTALL:append = " \
optee-os \
optee-client\
"
When i try to build it i get the error:
mk/subdir.mk:181: core/arch/arm/plat-colibri/sub.mk: No such file or directory
| make: *** No rule to make target 'core/arch/arm/plat-colibri/sub.mk'. Stop
So I tried manually setting the architecture appending the following in my local.conf:
OPTEEMACHINE = "imx"
OPTEEOUTPUTMACHINE = "imx"
OPTEE_ARCH = "arm32"
After that I got the error that optee-os was skipped from build, because nothing provided it because it was not listed in COMPATIBLE_MACHINE.
So i added `COMPATIBLE_MACHINE = "colibri-imx7-emmc"` in /layers/meta-arm/meta-arm/recipes-security/optee-os_3.16.0.bb
After that I got the error that the file `uTee-` was not built but required. So I manually built it with mkimage:
./tmp/sysroots-components/x86_64/u-boot-tools-native/usr/bin/mkimage -A arm -O linux -C none -d deploy/images/colibri-imx7-emmc/optee/tee.bin uTee
Now it did boot, but the /dev/tee did not show up. Running examples failed with `TEEC_InitializeContext failed with code 0xffff0008`. So I guess Tee ist no enabled.
---
I don't know how to help myself anymore. This looks like it is not supported but the porting guide states, that OPTEE is supported on all imx processors since imx6. Why is building it so difficult then? Why do I manually have to add my board to compatible machines. This does not like like the official way to enable optee in yocto on my processor. What is the official way then?