after downloading toolchain, BSP, sample rootfs from NVIDIA, we can build Kernel image.
But there are something we may change according to customized board.
Board configuration file: p3701.conf.common
*.dtsi generated by PINMUX spreadsheet
Device tree files under nv-public or nv-platform according to Orin adaption guide, such as tegra234-p3737-0000+p3701-0000.dts, tegra234-p3737-0000+p3701-xxxx-nv-common.dtsi
*** Please note that this reply is generated by LLM automatically ***
Based on the provided context, it appears that you have downloaded the toolchain, BSP, and sample root file system from NVIDIA for the Jetson AGX Orin platform. You are now looking to customize the board configuration and build a kernel image.
To customize the board configuration, you will need to modify the following files:
p3701-0000+p3737-0000_common.dtsi: This is the board configuration file generated by the PINMUX spreadsheet. You will need to update this file to reflect the customizations made to your board.
Device tree files under nvpublic or nvplatform: These files are specific to the Orin platform and need to be updated according to the Orin adaptation guide. Specifically, you will need to update the following files:
tegra234-p3737-0000-p3701-0000.dts
tegra234-p3737-0000-p3701-xxxx-nv-common.dtsi
These files are used to configure the device tree for the Jetson AGX Orin platform. You will need to update these files to reflect the customizations made to your board.
Once you have updated these files, you can build the kernel image using the toolchain provided by NVIDIA.
Here are the general steps to build the kernel image:
Extract the toolchain and BSP packages.
Update the board configuration file (p3701-0000+p3737-0000_common.dtsi) and device tree files (tegra234-p3737-0000-p3701-0000.dts and tegra234-p3737-0000-p3701-xxxx-nv-common.dtsi) to reflect the customizations made to your board.
Build the kernel image using the make command.
Note that the specific steps to build the kernel image may vary depending on the version of the toolchain and BSP you are using. It is recommended to refer to the NVIDIA Jetson Linux Developer Guide for detailed instructions on building the kernel image.
In comparison to other Jetson platforms, the Jetson AGX Orin platform has some unique features and requirements. For example, the device tree files for the Jetson AGX Orin platform are different from those for other Jetson platforms. Additionally, the board configuration file for the Jetson AGX Orin platform is generated by the PINMUX spreadsheet, which is specific to the Orin platform.
Therefore, when customizing the board configuration and building the kernel image for the Jetson AGX Orin platform, it is essential to follow the specific guidelines and instructions provided in the NVIDIA Jetson Linux Developer Guide for the Orin platform.
*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***
We are using Jetpack 6.2. It’s true that any device tree change will lead to new device tree build. I think kernel image should be independent of device tree. so we don’t need to rebuid kernel image if we changed device tree.
Just to add some details, think of the device tree as not actually being part of the kernel, but instead being arguments passed to kernel drivers and features as they load. If you don’t have a given driver or feature, then the device tree information would usually be ignored for that node. If you add a new driver or feature, and if that driver or feature depends on hardware which is not “plug-n-play”, then you’d need to append some device tree information in order for the driver to find the hardware.
The device tree content is available in the kernel source because it is a natural pairing to only provide device tree fragments for the features one has enabled in the kernel. Add a driver, and possibly (if not plug-n-play) you’d need more device tree nodes. It is quite common to automatically build a device tree as well when building an embedded system kernel with a new configuration, but it is also common to try the new kernel without a new tree and only build a new tree if the new driver/hardware cannot be found.
Devices on USB or PCI would normally not need a device tree change; adding a new PCIe slot or a new USB controller though would need a new device tree entry.
The PINMUX spreadsheet just happens to be a really convenient way to deal with modifying a carrier board. If one is routing pins differently on a custom carrier board, then you need the same nodes, but the addresses and pins associated with those tree fragments have to be edited.
Thanks linuxdev to comment.
Because the kernel loads the device tree, it’s generally a good idea to update both.
While you don’t always need to update the kernel just to enable existing device tree nodes, it’s highly recommended to update both if you’re developing a custom board. We assume you might be adding new features, and updating both the kernel and the device tree ensures they are consistent and work together seamlessly.