FDT_ERR_NOTFOUND for LVDS overlay on Torizon OS 7

Hello,

I am trying to convert my workflow to start using Torizon OS 7. For customizing the image, I use torizoncore-builder but the overlay that I use for a 7inch LVDS touch panel produces the following error:

=> Adding device-tree overlay 'overlays/verdin-imx8mp_dsi-to-lvds_panel-cap-touch-7inch-lvds_overlay.dts'
'verdin-imx8mp_dsi-to-lvds_panel-cap-touch-7inch-lvds_overlay.dts' compiles successfully.
Failed to apply '/tmp/tmpeh9ew945': FDT_ERR_NOTFOUND
error: cannot apply device tree overlays ['/tmp/tmpeh9ew945'] against device tree /storage/dt/usr/lib/modules/6.6.54-7.1.0-devel-gf7321c633d93/dtb/imx8mp-verdin-wifi-dahlia.dtb.
error: overlay 'overlays/verdin-imx8mp_dsi-to-lvds_panel-cap-touch-7inch-lvds_overlay.dts' is not applicable.

It worked without issues on Torizon OS 6.
I used the following branches for Torizon OS 7:

[submodule "linux"]
	path = linux
	url = git://git.toradex.com/linux-toradex.git
	branch = toradex_6.6-2.0.x-imx
[submodule "device-trees"]
	path = device-trees
	url = git://git.toradex.com/device-tree-overlays.git
	branch = toradex_6.6-2.0.x-imx

tcbuild.yaml file (for the Dahlia eval board):

# Documentation for this file: https://developer.toradex.com/torizon/os-customization/torizoncore-builder-tool-build-command/#detailedmanual
input:
  easy-installer:
    # TODO: Change back to toradex-feed when torizoncore-builder supports major release 7
    remote: https://artifacts.toradex.com/artifactory/torizoncore-oe-prerelease-frankfurt/scarthgap-7.x.y/monthly/2/verdin-imx8mp/torizon/torizon-docker/oedeploy/torizon-docker-verdin-imx8mp-Tezi_7.1.0-devel-202411+build.2.tar
    # toradex-feed:
    #   version: "7.1.0"
    #   release: monthly
    #   machine: verdin-imx8mp
    #   distro: ${DISTRO}
    #   variant: torizon-core-docker
    #   build-number: "2"
    #   build-date: "202411"
      
customization:
  splash-screen: media/company_logo.png
  device-tree:
    include-dirs:
      - linux/include
      - linux/arch/arm64/boot/dts/freescale
    custom: linux/arch/arm64/boot/dts/freescale/imx8mp-verdin-wifi-dahlia.dts
    overlays:
      add:
        - overlays/verdin-imx8mp_dsi-to-lvds_panel-cap-touch-7inch-lvds_overlay.dts
        - device-trees/overlays/verdin-imx8mp_spidev_overlay.dts
  filesystem:
    - rootfs-overlay
  
output:
  ostree:
    branch: app-image-branch
    commit-subject: "App image"
    commit-body: "TorizonCore OS Image for the company's App system"
  easy-installer:
    local: images/app-image
    name: "App image"
    description: "TorizonCore OS Image for the company's App system"
    accept-licence: true
    autoinstall: true
    autoreboot: true
    bundle:
      compose-file: application/docker-compose.lock.yml
      username: ${DOCKER_USERNAME}
      password: ${DOCKER_TOKEN}
      registry: ${DOCKER_REGISTRY}
    provisioning:
      mode: offline
      shared-data: shared-data.tar.gz

verdin-imx8mp_dsi-to-lvds_panel-cap-touch-7inch-lvds_overlay.dts:

/dts-v1/;
/plugin/;

/ {
	compatible = "toradex,verdin-imx8mp";
};

#include "verdin-imx8_mipi-dsi-to-sn65dsi84.dtsi"
#include "display-mi0700csp_sn65dsi84_overlay.dtsi"

#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>

&i2c4 {
    touchscreen@41 {
        compatible = "ilitek,ili251x";
        reg = <0x41>;

        interrupt-parent = <&gpio4>;
        interrupts = <25 IRQ_TYPE_EDGE_FALLING>;

        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_gpio_9_dsi>, <&pinctrl_i2s_2_bclk_touch_reset>;

        reset-gpios = <&gpio5 0 GPIO_ACTIVE_LOW>;

        status = "okay";
    };
};

&backlight {
	status = "okay";
};

&gpu_2d {
	status = "okay";
};

&gpu_3d {
	status = "okay";
};

/* LCDIF to MIPI-DSI */
&lcdif1 {
	status = "okay";
};

&mix_gpu_ml {
	status = "okay";
};

&ml_vipsi {
	status = "okay";
};

&vpu_g1 {
	status = "okay";
};

&vpu_g2 {
	status = "okay";
};

&vpu_vc8000e {
	status = "okay";
};

&vpu_v4l2 {
	status = "okay";
};

# Added to make it similar to verdin-imx8mp_dsi-to-lvds_panel-cap-touch-10inch-lvds_overlay.dts
# but the same error is there whether it is here or not
&reg_dsi_lvds {
	/* Verdin CTRL_SLEEP_MOCI# (SODIMM 256) */
	gpio = <&gpio4 29 GPIO_ACTIVE_HIGH>;
};

display-mi0700csp_sn65dsi84_overlay.dtsi:

&lvds_ti_sn65dsi84 {
	status = "okay";

	ports {
		#address-cells = <1>;
		#size-cells = <0>;

		port@2 {
			reg = <2>;

			lvds_out_panel: endpoint {
				remote-endpoint = <&panel_in_lvds>;
			};
		};
	};
};

&panel_lvds {
	compatible = "panel-lvds";
	backlight = <&backlight>;
	data-width = <24>;
	data-mapping = "vesa-24";
	height-mm = <86>;
	width-mm = <154>;
	status = "okay";

	panel-timing {
		clock-frequency = <44900000 51200000 63000000>;
		de-active = <0>;
		hactive = <1024>;
		hback-porch = <160>;
		hfront-porch = <16 160 216>;
		hsync-len = <1 70 140>;
		pixelclk-active = <1>; /* positive edge */
		vactive = <600>;
		vback-porch = <23>;
		vfront-porch = <1 12 127>;
		vsync-len = <1 10 20>;
	};

	port {
		panel_in_lvds: endpoint {
			remote-endpoint = <&lvds_out_panel>;
		};
	};
};

Why am I getting this FDT_ERR_NOTFOUND error?

Best regards,

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 FDT_ERR_NOTFOUND error you’re encountering when applying the device tree overlay on Torizon OS 7 is likely due to compatibility issues between the overlay and the base device tree blob (DTB) for the imx8mp-verdin-wifi-dahlia.dtb. Here are some steps and considerations to help resolve this issue:

  1. Compatibility Check: Ensure that the overlay is compatible with the DTB used in Torizon OS 7. The overlay might have been compatible with Torizon OS 6, but changes in the device tree structure or requirements in Torizon OS 7 could cause incompatibility.

  2. Review Overlay and DTB: Examine the overlay and the base DTB to ensure that all nodes and properties expected by the overlay are present in the DTB. The error suggests that the overlay is trying to reference nodes or properties that do not exist in the DTB.

  3. Update Overlay Definitions: Check the compatible property in the overlay to ensure it matches the compatible property of the base device tree. This is crucial for the overlay to be applied correctly.

  4. Investigate Changes in Torizon OS: Look into any changes in the device tree structure between Torizon OS 6 and Torizon OS 7 that might affect the overlay application. This could involve changes in node names, paths, or required properties.

  5. Modify Overlay or DTB: Depending on your findings, you may need to modify the overlay to align with the current DTB or update the DTB to support the overlay. This might involve adding missing nodes or properties to the DTB or adjusting the overlay to match the new structure.

By following these steps, you should be able to identify and resolve the cause of the FDT_ERR_NOTFOUND error. If the issue persists, further investigation into the specific changes between the Torizon OS versions and the device tree configurations may be necessary.

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

Enable 10.1" LVDS display on Mallow carrier board.

Greetings @mnano,

The issue is the panel_lvds node in display-mi0700csp_sn65dsi84_overlay.dtsi. You’re referencing this node by it’s alias, but this node no longer exists in the base device tree in Torizon OS 7. See here in our display overlay how panel_lvds is handled: display-lt170410_sn65dsi84_overlay.dtsi « overlays - device-tree-overlays.git - Sources for Device Tree Overlays

Instead of using the alias for this non-existent node, we instead create a new node under the root node. If you make this adjustment then the overlay should now apply cleanly, at least it did on my end.

Best Regards,
Jeremias