Custom machine config based on verdin-am62

I am trying to create a custom machine configuration in yocto that is based on the verdin-am62 machine config. I have a custom layer with the following machine config in conf/machine/custom-verdin-am62.conf:

MACHINEOVERRIDES =. "verdin-am62:"

require conf/machine/verdin-am62.conf

KERNEL_DEVICETREE = " \
    ${KERNEL_DTB_PREFIX}k3-am625-verdin-custom1.dtb \
    ${KERNEL_DTB_PREFIX}k3-am625-verdin-custom2.dtb \
"

TEZI_EXTERNAL_KERNEL_DEVICETREE_BOOT = ""

When attempting to build the linux-toradex-ti recipe, I am receiving the following error:

| DEBUG: Executing shell function do_kernel_metadata
| NOTE: do_kernel_metadata: for summary/debug, set KCONF_AUDIT_LEVEL > 0
| ERROR: Could not locate BSP definition for custom-verdin-am62/standard and no defconfig was provided
| WARNING: exit code 1 from a shell command.

I’m not how the defconfig is specified in the verdin-am62 machine config, but it seems like one of the kernel recipes will default to using the “defconfig” file present in the kernel repo.

However with my custom machine config, bitbake doesn’t seem to be unpacking the linux-toradex-ti source into the working directory.

Hi, I’m the Toradex AI Assistant.

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


The issue you’re encountering is related to how Yocto handles BSP definitions for custom machine configurations. Based on the Toradex documentation, here’s how to properly create a custom machine configuration based on verdin-am62(1).

Solution: Create a Machine-Specific Extra Configuration

Instead of creating a completely new machine configuration, you should create a machine-specific extra configuration file. According to the Toradex documentation, this is the recommended approach(1).

Step 1: Create Machine Extra Configuration

Create a file conf/machine/verdin-am62-extra.conf in your custom layer(1):

KERNEL_DEVICETREE:append = " \
    freescale/k3-am625-verdin-custom1.dtb \
    freescale/k3-am625-verdin-custom2.dtb \
"

(1)

Step 2: Include the Extra Configuration in Your Layer

Add the following line to the end of your conf/layer.conf file(1):

include conf/machine/verdin-am62-extra.conf

(1)

Step 3: Use the Original Machine Configuration

Instead of creating a custom machine, use the original verdin-am62 machine configuration and set your MACHINE variable in local.conf:

MACHINE = "verdin-am62"

Why This Approach Works

The error you’re seeing occurs because when you create a completely new machine configuration, Yocto expects a corresponding BSP definition and defconfig for that specific machine name. The Toradex BSP layers are configured to work with the predefined machine names like verdin-am62(1).

By using the machine-extra.conf approach, you:

  • Inherit all the proper BSP definitions from the original verdin-am62 configuration
  • Avoid conflicts with kernel recipe expectations
  • Follow the Toradex-recommended pattern for customization

For TI-based SoMs Specifically

Since you’re working with Verdin AM62 (TI-based), ensure your custom device trees are placed in the correct directory structure and that your .bbappend files target the correct kernel recipe (linux-toradex-ti)(1).

This approach should resolve the “Could not locate BSP definition” error while allowing you to add your custom device trees.

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.

Greetings @camja014,

The problem is that you’re essentially defining a new machine by the name of custom-verdin-am62. In our BSP we use a kernel cache repository in order to construct the complete kernel configuration. This kernel cache repository uses the name of the machine to decide what configuration to create: Making sure you're not a bot!

Obviously our repository doesn’t have a configuration for a machine called custom-verdin-am62. Which leads to the error you observed.

What we would recommend instead is including your extra configurations file into the main verdin-am62.conf file instead of the other way around as you did here. See the example in the documentation here as reference: Customize an Image | Toradex Developer Center

That way the machine name is still verdin-am62 and everything should work as expected.

Best Regards,
Jeremias

Hi Jeremias,

Thank you, that helps a lot. The recommended approach is what I already have in place. I was attempting to create a custom machine as an exercise to learn more about Yocto/OpenEmbedded.