Build DTBs with Yocto
DTBs are built automatically as part of a full Yocto image build. To rebuild only the device trees after a DTS change without a full image rebuild:- Enter a kas shell:
- Force the kernel recipe to recompile (picks up DTS changes):
- Rebuild the device image to repackage the updated DTBs into
dtb.bin:
tmp/deploy/images/<machine>/dtbs/.
Deploy DTBs to the device
After a full Yocto build, flash the complete image to update all partitions including the DTB partition:Build DTBs standalone (without Yocto)
When using thekmake standalone workflow, build only the device trees with:
.dtb and .dtbo files are placed in
../kobj/arch/arm64/boot/dts/qcom/.
Package multiple dtbs as FIT image
To package them into a flashabledtb.bin FIT image, use make_fitimage.sh
from the qcom-dtb-metadata
repository (requires the kmake-image Docker toolchain):
Package dtb as single default image
To include your dtb as single and default device tree blob to be picked by uefi during boot, usegenerate_boot_bins.sh to package dtb.bin, passing explicitly
your dtb to it.
kmake-image utilities refer its project readme.
Deploy DTBs to the device
After generatingdtb.bin with make_fitimage.sh that packages multiple dtbs
or generate_boot_bins.sh that packages single dtb:
Flash both
efi.bin and dtb.bin together after a kernel or DTS change to
keep the kernel and device tree in sync. See
Install & boot the kernel
for the full incremental flash sequence.Validate DTB selection at boot
After the device reboots, confirm the expected device tree was loaded. Check the loaded compatible string:compatible string of your board DTS. For example,
for a QCS6490 RB3 Gen 2:

