From ProventusNova DeveloperWiki
Line 35: Line 35:


This will load the overlay at boot time.
This will load the overlay at boot time.


6. If you do not want to load the device tree overlay at boot time, skip step 5 and do this instead. Copy '''your_overlay.dtbo''' to '''Linux_for_Tegra/rootfs/boot/'''.

7. After flashing the board the file will be under '''/boot/''' directory. Modify '''extlinux.conf''' file inside '''/boot/extlinux/''' directory and add the following:

<syntaxhighlight lang="bash">
TIMEOUT 30
DEFAULT primary

MENU TITLE L4T boot options

LABEL primary
MENU LABEL primary kernel
LINUX /boot/Image
INITRD /boot/initrd
APPEND ${cbootargs}
FDT /boot/dtb/kernel_tegra234-p3768-0000+p3767-0000-nv.dtb
OVERLAY /boot/your_overlay.dtbo

</syntaxhighlight>

8. Reboot the board so the changes are applied.

Revision as of 17:56, 24 November 2025

Adding custom device tree overlay to JetPack 6.X

Keywords: NVIDIA Jetson, JetPack, kernel customization, device tree overlays, dtbo

Description

This wiki page shows how to add a custom device tree overlay for NVIDIA platforms with Jetpack 6.X.

Adding custom device tree overlay

Take your_overlay.dts as the custom device tree overlay file to be added.

1. In Jetpack 6.X device tree overlays live in directory: hardware/nvidia/t23x/nv-public/overlay/. Add your_overlay.dts device tree overlay file to this directory.

2. In order to build this file, add the following to the Makefile inside the same directory.

 
dtbo-y += your_overlay.dtbo

3. Inside Linux_for_Tegra/source directory, export environment variables for compiling and compile dtbs.

 
export CROSS_COMPILE=$HOME/l4t-gcc/aarch64--glibc--stable-2022.08-1/bin/aarch64-buildroot-linux-gnu-
export KERNEL_HEADERS=$PWD/kernel/kernel-jammy-src

make dtbs

Note: Compiled device tree overlay files will be under: Linux_for_Tegra/source/kernel-devicetree/generic-dts/dtbs/.

4. Copy your_overlay.dtbo to Linux_for_Tegra/kernel/dtb.

5. Add your_overlay.dtbo to the machine conf used for flashing. For example, for NVIDIA Jetson Orin Nano developer kit we modify file jetson-orin-nano-devkit.conf and add our overlay to variable OVERLAY_DTB_FILE

 
OVERLAY_DTB_FILE+=",tegra234-p3768-0000+p3767-0000-dynamic.dtbo,your_overlay.dtbo";

This will load the overlay at boot time.


6. If you do not want to load the device tree overlay at boot time, skip step 5 and do this instead. Copy your_overlay.dtbo to Linux_for_Tegra/rootfs/boot/.

7. After flashing the board the file will be under /boot/ directory. Modify extlinux.conf file inside /boot/extlinux/ directory and add the following:

 
TIMEOUT 30
DEFAULT primary

MENU TITLE L4T boot options

LABEL primary
      MENU LABEL primary kernel
      LINUX /boot/Image
      INITRD /boot/initrd
      APPEND ${cbootargs}
      FDT /boot/dtb/kernel_tegra234-p3768-0000+p3767-0000-nv.dtb
      OVERLAY /boot/your_overlay.dtbo

8. Reboot the board so the changes are applied.