Yocto Custom DT on Aquila AM69

Hi, I’m the Toradex AI Assistant.

I might make mistakes or occasionally get you wrong. Our support team will step in if needed.


I can help you troubleshoot your custom device tree issue on the Aquila AM69. Based on the Toradex documentation, there are specific steps for both adding the device tree to the kernel build and configuring U-Boot to load it.

Kernel Configuration

First, ensure your custom device tree is properly added to the kernel build. You need to add your device tree file to the KERNEL_DEVICETREE variable in a machine-specific configuration file (1):

KERNEL_DEVICETREE:append = " ti/my-custom-devicetree-file.dtb"

(1)

For the Aquila AM69, create a machine configuration file like aquila-am69-extra.conf and include it in your layer’s conf/layer.conf file (1):

include conf/machine/aquila-am69-extra.conf

(1)

U-Boot Configuration

The critical step that’s often missed is configuring U-Boot to actually load your custom device tree. You need to create a U-Boot bbappend file (1).

For TI-based SoMs like the Aquila AM69, create recipes-bsp/u-boot/u-boot-toradex-ti%.bbappend (1):

do_configure:append() {
    # Remove existing fdtfile, if there is one
    sed -i '/"fdtfile=.*\\0" \\/d' ${S}/include/configs/j784s4_evm.h
    # Add new fdtfile
    sed -i 's/\("fdt_board=.*\\0" \\\)/\0\n "fdtfile=my-custom-devicetree-file.dtb\\0" \\/' ${S}/include/configs/j784s4_evm.h
}

(1)

Verification Steps

To verify your custom device tree is being loaded:

  1. Check the built image: Verify your .dtb file exists in the boot partition
  2. U-Boot environment: In U-Boot console, check the fdt_file environment variable matches your custom device tree name (2)
  3. Boot logs: Check if your custom device tree modifications are taking effect during boot

Common Issues

  • File naming: Ensure your device tree file name matches exactly between the kernel build and U-Boot configuration
  • Path structure: For TI-based modules, device trees typically go in the ti/ subdirectory
  • Build order: Make sure both kernel and U-Boot changes are included in your build

If you’re still having issues, could you share:

  • Your exact device tree file name
  • The contents of your machine configuration file
  • Your U-Boot bbappend configuration

This will help identify where the configuration might not be matching up.

Best regards, Toradex AI Assistant.


Did you like my answer? :+1: :-1:

If I answered your question, please tick the “Solution” checkbox.

For follow-up questions to me, please use @ToradexAI in your post.