内核编译完成后,设备树二进制文件的输出位置及是否在zImage中?
Hey there! Let's tackle your two kernel-related questions one by one:
Once your kernel build completes, the compiled DTB files live in the architecture-specific boot DTS directory within your kernel source tree.
- For ARM systems: Look under
arch/arm/boot/dts/ - For ARM64 systems: Check
arch/arm64/boot/dts/ - For other architectures (like PowerPC), the path follows the same pattern:
arch/[arch-name]/boot/dts/
Within that directory, you'll often find subdirectories grouped by SoC or board family (e.g., broadcom/ for Raspberry Pi boards, ti/ for Texas Instruments chips) where the actual .dtb files are stored.
Nope, by default the compiled DTBs are not embedded inside the zImage.
The zImage is strictly the compressed kernel executable. DTBs are standalone binary files that need to be loaded independently during the boot process—usually by a bootloader like U-Boot, or by the device's firmware.
That said, it's possible to create combined images (like a zImage-dtb file or a Flattened Image Tree/FIT image) that package the kernel and DTB together. But this is an optional step; you'd need to explicitly configure or build these combined images separately, as it's not the default kernel build behavior.
内容的提问来源于stack exchange,提问作者Dimitrius J

