i’m working with a carrier board from seed studio and i could get the jetpack 6.2 kernel working on the board after flashing with the sdk manager.
Now, i want to compile my own kernel. I got the kernel sources using the source_sync.sh script with tag as 36.4.3 appropriate for jetpack6.2.
did the following to compile kernel:
- got correct compiler from the website and set the path appropriately
- make ARCH=arm64 tegra_prod_defconfig menuconfig, select custom drivers
- make ARCH=arm64
It did compile without errors.
However there are no dts files for my board in the boot directory: arm/arm64/boot/dts/nvidia/
“make ARCH=arm64 dtbs” doesn’t build for my board. I had to copy dts files and edit the Makefile to include:
tb-$(CONFIG_ARCH_TEGRA_234_SOC) += tegra234-p3768-0000+p3767-0000-nv.dtb
dtb-$(CONFIG_ARCH_TEGRA_234_SOC) += tegra234-p3768-0000+p3767-0001-nv.dtb
dtb-$(CONFIG_ARCH_TEGRA_234_SOC) += tegra234-p3768-0000+p3767-0003-nv.dtb
dtb-$(CONFIG_ARCH_TEGRA_234_SOC) += tegra234-p3768-0000+p3767-0004-nv.dtb
dtb-$(CONFIG_ARCH_TEGRA_234_SOC) += tegra234-p3768-0000+p3767-0005-nv.dtb
I copied dts and dtsi files from the path:
~/nvidia/nvidia_sdk/JetPack_6.2_Linux_JETSON_ORIN_NANO_TARGETS/Linux_for_Tegra/source/hardware/nvidia/t23x/nv-public
I tried compiling it and fixing many header missing errors enroute. Now, after i have resolved all the missing headers i get the following error:
DTC arch/arm64/boot/dts/nvidia/tegra234-p3768-0000+p3767-0000-nv.dtb
arch/arm64/boot/dts/nvidia/nv-soc/tegra234-base-overlay.dtsi:734.41-766.4: ERROR (duplicate_label): /mgbe-vm-irq-config: Duplicate label ‘mgbe_vm_irq_config’ on /mgbe-vm-irq-config and /bus@0/mgbe-vm-irq-config
ERROR: Input tree has errors, aborting (use -f to force output)
It looks like i have two dtsi files with the same label.
I wanted to know if what i’m doing is right ? Is this the right approach to build custom device tree for a board ? Is there a script which copies the necessary board files from the platform directory into kernel boot directory ?
The board is a replica of the development kit hence there should be no changes in the device tree.
The kernel booted correctly from SDK manager flashed image with original device tree files but it doesn’t boot when i replaced only the custom kernel image in the boot directory.
Any help here please
