AM62L: Arago Project Porting Issues for Custom Hardware (AM62L / TF-A)

Part Number: AM62L


Hi,

I am working on customizing the Arago Project for a custom AM62L-based hardware platform. As part of this effort, I have added a new layer (meta-custom-ti) and introduced hardware-specific overrides and append files to replace the TI reference hardware sources.

While building Trusted Firmware-A (TF-A) using BitBake, I encounter the following error:

 

dir: ~/Anandhu/oe-layersetup/build
custom_admin@(docker)$ bitbake trusted-firmware-a
NOTE: Started PRServer with DBfile: /home/custom_admin/Anandhu/oe-layersetup/build/cache/prserv.sqlite3, Address: 127.0.0.1:43183, PID: 3355835
Loading cache: 100% |############################################| Time: 0:00:01
Loaded 5445 entries from dependency cache.
Parsing recipes: 100% |##########################################| Time: 0:00:03
Parsing of 3416 .bb files complete (3414 cached, 2 parsed). 5447 targets, 786 skipped, 0 masked, 0 errors.
NOTE: Resolving any missing task queue dependencies

Build Configuration:
BB_VERSION           = "2.8.1"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "ubuntu-22.04"
TARGET_SYS           = "aarch64-oe-linux"
MACHINE              = "am62lxx-stamp"
DISTRO               = "arago"
DISTRO_VERSION       = "2025.01"
TUNE_FEATURES        = "aarch64"
TARGET_FPU           = ""
meta-ti-foundational 
meta-ti-ml           = "HEAD:93d1c18850f4bb73de4b09b740fb4ad51eecfe2d"
meta-arago-distro    
meta-arago-extras    
meta-arago-test      = "HEAD:51f6bfa0b61c07dd1542e4aafc83747623355f82"
meta-virtualization  = "HEAD:af1db2042caf8021d767dce1b26c08b59b96f3d1"
meta-networking      
meta-python          
meta-oe              
meta-gnome           
meta-filesystems     
meta-multimedia      = "HEAD:e621da947048842109db1b4fd3917a02e0501aa2"
meta-lts-mixins      = "HEAD:a8046d5ec53b1856169ac795aa87cb0d5db84c04"
meta-ti-extras       
meta-beagle          
meta-ti-bsp          = "HEAD:9a30c7b97a979fa66cb22b2c2ce1d3b7d466ee24"
meta-arm             
meta-arm-toolchain   = "HEAD:0f1e7bf92c89759f0ab74cfa5be4ee47b092ad46"
meta-clang           = "HEAD:057ee563305e9484b29d02347aeafdadc5ea28ed"
meta                 = "HEAD:4cf131ebd157b79226533b5a5074691dd0e1a4ab"
meta-custom-ti       = "master:9997a06c04594d6cdff7d6e8e6b93112d75a59d5"

Sstate summary: Wanted 11 Local 0 Mirrors 0 Missed 11 Current 300 (0% match, 96% complete)
Initialising tasks: 100% |#######################################| Time: 0:00:01
NOTE: Executing Tasks
ERROR: trusted-firmware-a-2.13+git-r0 do_install: Unsupported TFA_INSTALL_TARGET target bl31
ERROR: trusted-firmware-a-2.13+git-r0 do_install: ExecutionError('/home/custom_admin/Anandhu/oe-layersetup/build/arago-tmp-default-glibc/work/am62lxx_stamp-oe-linux/trusted-firmware-a/2.13+git/temp/run.do_install.3357604', 1, None, None)
ERROR: Logfile of failure stored in: /home/custom_admin/Anandhu/oe-layersetup/build/arago-tmp-default-glibc/work/am62lxx_stamp-oe-linux/trusted-firmware-a/2.13+git/temp/log.do_install.3357604
ERROR: Task (/home/custom_admin/Anandhu/oe-layersetup/sources/meta-arm/meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.10.4.bb:do_install) failed with exit code '1'
NOTE: Tasks Summary: Attempted 1017 tasks of which 1005 didn't need to be rerun and 1 failed.
NOTE: Writing buildhistory
NOTE: Writing buildhistory took: 4 seconds

Summary: 1 task failed:
  /home/custom_admin/Anandhu/oe-layersetup/sources/meta-arm/meta-arm/recipes-bsp/trusted-firmware-a/trusted-firmware-a_2.10.4.bb:do_install
    log: /home/custom_admin/Anandhu/oe-layersetup/build/arago-tmp-default-glibc/work/am62lxx_stamp-oe-linux/trusted-firmware-a/2.13+git/temp/log.do_install.3357604
Summary: There were 2 ERROR messages, returning a non-zero exit code.
dir: ~/Anandhu/oe-layersetup/build
custom_admin@(docker)$

 

Trusted-firmware-a_%.bbappend  file from the meta-custom-ti is posted below :


FILESEXTRAPATHS:prepend := "${THISDIR}/files:"

SRC_URI:am62lxx = "git://github.com/Anandhu-Sudha/arm-trusted-firmware.git;protocol=https;branch=ti-master"

SRCREV:pn-trusted-firmware-a:am62lxx = "e601819087f7866806624b69eb79544538fa8736"

S = "${WORKDIR}/git"

TFA_INSTALL_TARGET:am62lxx = "bl31 bl1"

EXTRA_OEMAKE:append = " DEBUG=1"
COMPATIBLE_MACHINE = "k3"

Observations

  • The same customized TF-A sources build and run correctly when built locally outside of Yocto.

  • The BitBake environment itself is functional, as I am able to successfully build the complete filesystem and boot images for the AM62L EVM using the default TI configuration.

  • The issue appears only after introducing the custom BSP layer, and only during the TF-A do_install task.

  • The error indicates that TFA_INSTALL_TARGET is resolving to bl31, which is reported as unsupported by the meta-arm TF-A recipe.

Questions

  1. What could cause TFA_INSTALL_TARGET to be set to bl31 when using a custom layer, while the default TI configuration builds successfully?

  2. What is the recommended way to debug variable changes or overrides introduced by a custom BSP layer in the Arago/Yocto environment?

  3. Is there an official Arago Project or TI-recommended porting guide for bringing up custom hardware (similar to Yocto BSP porting documentation)?

Any guidance on the correct approach to resolve this issue or pointers to relevant documentation would be greatly appreciated.

Regards,
Anandhu

  • Hi Anandhu,

    Does your changes work without you using Yocto? I mean using the top level makefile with our SDK

    https://software-dl.ti.com/processor-sdk-linux/esd/AM62LX/11_02_08_02/exports/docs/linux/Overview/Top_Level_Makefile.html

    Best Regards,

    Suren

  • Dear Anandhu, 

    In regards to your questions:
    1) Your custom layer recipe (Trusted-firmware-a_%.bbappend) is setting "TFA_INSTALL_TARGET" to "bl31". 
    2) One can utilize the "-e" option for bitbake to check set values of variables. For example "bitbake -e trusted-firmware-a | grep ^TFA_INSTALL_TARGET".
    3) That is a question for @Suren. 


    A question for you:
    What config file did you utilize to setup your layer ? For example "./oelayersetup -f <config name>" ?

    Also, typically there is no need to set "TFA_INSTALL_TARGET:am62lxx = "bl31 bl1" " explicitly in the custom layer .bbappend recipe, since that is already set within the meta-ti .bbappend recipe. 

    Kind Regards,

    Antonios 

  • Hi Antonios,

    Thank you for the clarification. Regarding the setup script, I do not have a file named ./oelayersetup in my directory; however, I have been using ./oe-layertool-setup.sh -f configs/arago-scarthgap-config.txt for my project setup.

    In regards to your point about TFA_INSTALL_TARGET, you mentioned that it is already set within the meta-ti layer. Since I am working with custom hardware and utilizing a custom layer as mentioned in my post, could you explain how the target selection is prioritized when layer overriding takes place? I want to ensure my custom board configuration is applied correctly without creating conflicts with the base meta-ti settings.

    Additionally, is there an official Arago porting guide or documentation that explains how the sources are structured and the best practices for customizing the build for proprietary hardware?

    Kind Regards,

    Anandhu S

  • Hi Suren,

    Thank you for the suggestion. Regarding the top-level Makefile, I haven't utilized it directly as it would require specific modifications for our custom board configuration.

    However, as I mentioned in the post, I have already performed successful manual builds of the ATF, U-Boot, and Kernel using the standalone SDK cross-compiler by mirroring the directory structure and files of the AM62Lx EVM. These components build correctly in a local, standalone environment.

    To clarify, could you explain how the success of the standalone build relates to the current Yocto integration issue? My goal is to understand if there is a specific reason why the Yocto recipes might be failing to produce the same results that I am seeing with the manual build process.

    Best Regards,

    Anandhu S