How to Add a Custom Device Tree Overlay to Verdin AM62 Yocto Build?

Hi @raju3003!

I’ve tested it, and here’s what is working:

.
├── conf
│   └── layer.conf
├── COPYING.MIT
├── README
└── recipes-kernel
    └── linux
        ├── device-tree-overlays-ti
        │   └── verdin-am62_gpio-pullup.dts
        └── device-tree-overlays-ti_%.bbappend

verdin-am62_gpio-pullup.dts:

/dts-v1/;
/plugin/;

#include <dt-bindings/gpio/gpio.h>
#include "k3-pinctrl.h"

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

&main_pmx0 {
        pinctrl_custom_pullup: main-custom-pullup {
                pinctrl-single,pins = <
                        AM62X_IOPAD(0x0094, PIN_OUTPUT_PULLUP, 7)
                >;
        };
};

device-tree-overlays-ti_%.bbappend:

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

SRC_URI:append = " file://verdin-am62_gpio-pullup.dts"

do_collect_overlays:prepend () {
    cp ${WORKDIR}/verdin-am62_gpio-pullup.dts ${S}
}

TEZI_EXTERNAL_KERNEL_DEVICETREE_BOOT:append = " verdin-am62_gpio-pullup.dtbo"

Please edit your project with these changes and try to build it again.

Best regards.
Lucas Azeituno

1 Like