On Mon, Aug 16, 2021 at 06:09:34PM -0300, Fabio Estevam wrote: > Hi Paul, > > On Sun, Aug 15, 2021 at 4:27 PM Paul Liu wrote: > > > No. I think they actually use fip.bin but just not upstreamed yet. Please > > see the "Firmware version" in the list. For Compulab we are using mainline > > U-boot. But for imx8mm-evk it is NXP released firmware. > > > > And yes we do use mainline ATF and mainline OPTEE. I'll explain how to > > build all of them. > > > > # OPTEE > > > > 1. export ARCH=arm > > 2. export CROSS_COMPILE=arm-linux-gnueabihf- > > 3. export CROSS_COMPILE64=aarch64-linux-gnu- > > 4. make PLATFORM=imx PLATFORM_FLAVOR=mx8mm_cl_iot_gate O=build.mx8mmevk \ > > CFG_TEE_CORE_LOG_LEVEL=2 \ > > CFG_TEE_TA_LOG_LEVEL=2 \ > > CFG_TEE_CORE_DEBUG=y \ > > CFG_EXTERNAL_DTB_OVERLAY=y \ > > CFG_DT=y \ > > CFG_DT_ADDR=0x52000000 \ > > CFG_DEBUG_INFO=y > > > > > > And we got tee-header_v2.bin tee-pager_v2.bin and tee-pageable_v2.bin. > > These files will be used in the TF-A stage. > > > > Then we start building U-boot (BL31). > > > > # U-boot (BL31) > > > > 1. export ARCH=arm64 This is actively wrong and breaks building U-Boot in some cases. You do not ever need to set ARCH in the environment, and setting it to the wrong one (it would be arm, not arm64) causes invalid symlinks to be made in some cases. I see that, sigh, this mistake has made it in to the docs twice, again. -- Tom