Unbuildable virtual/dtb on CUSTOM MACHINE Verdin AM62 in Yocto

Hello,
I need to CUSTOMIZE verdin-am62.conf MACHINE, creating my new one with some settings like changing the device tree overlays and other adjustments.
However, I’m encountering an issue while building a custom image, I receive the following error:

ERROR: Nothing PROVIDES 'virtual/dtb' (but /opt/toradex-oe-core/build.am62/../layers/meta-xpeak/recipes-xpeak/images/xpeak-minimal-image.bb DEPENDS on or otherwise requires it)
device-tree-overlays PROVIDES virtual/dtb but was skipped: incompatible with machine stellihorn-k3r5 (not in COMPATIBLE_MACHINE)
device-tree-overlays-mainline PROVIDES virtual/dtb but was skipped: incompatible with machine stellihorn (not in COMPATIBLE_MACHINE)
device-tree-overlays-ti PROVIDES virtual/dtb but was skipped: PREFERRED_PROVIDER_virtual/dtb set to device-tree-overlays-mainline, not device-tree-overlays-ti
ERROR: Required build target 'xpeak-minimal-image' has no buildable providers.
Missing or unbuildable dependency chain was: ['xpeak-minimal-image', 'virtual/dtb']

it seems that no provider for the dtb is compatible with my custom machine stellihorn
This is my Stellihorn.conf:

MACHINEOVERRIDES =. "verdin-am62:"
require conf/machine/verdin-am62.conf
KERNEL_DEVICETREE:append = " stellihorn.dtb"
MACHINE_PREFIX_stellihorn = "verdin-am62"

Has anyone experienced similar issues or knows how to resolve the compatibility for virtual/dtb with this custom machine? Any help is greatly appreciated!
Thanks in advance for your assistance.

Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


The error you’re encountering indicates that the virtual/dtb provider is not compatible with your custom machine configuration stellihorn. This is likely due to the COMPATIBLE_MACHINE variable not being set correctly for the device tree overlays you are trying to use.

Here are a few steps you can take to resolve this issue:

  1. Check COMPATIBLE_MACHINE: Ensure that the COMPATIBLE_MACHINE variable in the recipes providing virtual/dtb includes your custom machine stellihorn. You may need to modify the COMPATIBLE_MACHINE variable in the device-tree-overlays recipes to include stellihorn.

  2. Modify the Device Tree Overlay Recipe: If you have a custom device tree overlay, make sure its recipe is set up to be compatible with your custom machine. You can do this by adding stellihorn to the COMPATIBLE_MACHINE variable in the recipe file.

  3. Set PREFERRED_PROVIDER: Ensure that the PREFERRED_PROVIDER_virtual/dtb is set correctly in your configuration to point to the correct provider that is compatible with your machine.

  4. Verify MACHINEOVERRIDES: Double-check your MACHINEOVERRIDES and ensure it is correctly set to include verdin-am62. This should help in inheriting the necessary configurations from the verdin-am62 machine.

  5. Review Kernel Device Tree Configuration: Make sure that the KERNEL_DEVICETREE variable is correctly set to include your custom device tree (stellihorn.dtb). This should be appended correctly in your machine configuration.

By ensuring that the COMPATIBLE_MACHINE variable is correctly set and that your custom machine configuration is properly inheriting from verdin-am62, you should be able to resolve the issue with the virtual/dtb provider. If these steps do not resolve the issue, you may need to further investigate the specific recipes and configurations involved in your build setup.

Please, also check if these links can help you solve your problem:

Verdin AM62 torizon core docker not booting from SD.

Hi @YRP88!

What are the other adjustments that you need?
We do not recommend customizing/editing verdin-am62.conf, instead you can follow this article, which teaches how to enable your device tree overlays in Yocto.

Feel free to ask if you have any issues or doubts.

Best regards.
Lucas Azeituno

Hi @lucas_az.tx,
I’ve already created a custom overlay, I’m using it, and it works. I want to create a custom machine Stellihorn.conf that inherits from verdin-am62.conf. Why is it not recommended to create a custom machine? Or are you suggesting I use overlays to modify the DTB?

Thanks for your assistance.
Best regards,
Yuri

Hi @YRP88!

Just a few steps back, what do you want to achieve using the custom machine? What adjustments do you need?

You don’t need to create a custom machine if you want to modify the device tree using overlays. You can add it from user space, or using Yocto as said before.

Best regards.
Lucas Azeituno.

Hi Lucas,

Thank you for your response! I would like to create a custom machine to gain more flexibility in customizing the DTS and tailoring it specifically to the board I’ve built. This would allow me to be independent of Toradex’s choices regarding the kernel and M4 management.

While overlays are useful, in my case I need more comprehensive control and specific integrations that require deeper modifications. Could you provide me with more details on how to properly set up a custom machine?

Thank you very much for your support!

Best regards,
Yuri

Hi @YRP88!

Which OS and OS version are you trying to build? I tried your stellihorn.conf on BSP 7 and it worked.

I had to create two machines, stellihorn.conf and stellihorn-k3r5.conf. The second one have just one line (for testing purposes), and you can find it below:

require conf/machine/verdin-am62-k3r5.conf

Could try it on BSP 7, please?

Best regards.
Lucas Azeituno

Hi Lucas,

Thank you for your message. I appreciate your insights regarding the BSP 7 build, which has been updated.

I’m not quite sure how your stellihorn.conf worked successfully, as I encountered some issues. In my conf/local.conf, I replaced the machine configuration with:

MACHINE ?= "stellihorn"

We identified that our machine was missing in the downstream machine configuration, so we added it there as follows:

MACHINES_DOWNSTREAM_DISTRO_DEFAULT = "apalis-imx8 colibri-imx8x verdin-imx8mm verdin-imx8mp verdin-am62 verdin-am62-k3r5 stellihorn"

After realizing this, I simplified stellihorn.conf to only include the necessary lines:

require conf/machine/verdin-am62.conf
KERNEL_DEVICETREE = "ti/stellihorn.dtb"

The stellihorn-k3r5.conf remains as you mentioned, with just the one line:

require conf/machine/verdin-am62-k3r5.conf

With these adjustments, I no longer have any issues with the kernel, which now compiles correctly with the machine set to stellihorn.

We managed to successfully build the Stellihorn machine. Thank you for your support!

Best regards,
Yuri Pezzotta

Hi @YRP88!

I’m glad to hear that you solved the issue.
I’ll mark your answer as a solution and consider this topic solved.

Feel free to open another topic if you face any issues or doubts.

Best regards.
Lucas Azeituno