Building the Flashing Kernel Sources#
Note
Ensure that you have sphinx-build installed and that PATH is updated, or set the SPHINXBUILD make variable to point to the full path of the sphinx-build executable.
To build the flashing kernel#
Extract the flashing kernel sources using the following commands on the host:
t23x:
cd ${NV_WORKSPACE}/drive-foundation/tools/flashtools/
flashing_kernel/src/t23x
tar xvf drive-oss-flashing_kernel-src.tar.bz2
cd drive-oss-flashing_kernel-src/drive-oss-src
Set up the environment macros:
export ARCH=arm64
export CROSS_COMPILE=${NV_WORKSPACE}/toolchains/aarch64--glibc--stable-2022.03-1/bin/aarch64-buildroot-linux-gnu-
export LOCALVERSION="-tegra"
Create an output directory, and then configure the kernel for the board:
mkdir –p out-t234-linux/out
make -C kernel-5.10 O=${PWD}/out-t234-linux/out clean
Add the following command:
make -C kernel-5.10 O=${PWD}/out-t234-linux/out tegra_defconfig
Build the kernel:
make -C kernel-5.10 O=${PWD}/out-t234-linux/out –j4
Note
If the above command fails, enter the make
command without the j<number>
option.
Copy the uncompressed kernel image with the following command:
t23x:
cp ${PWD}/out-t234-linux/out/arch/arm64/boot/Image ${NV_WORKSPACE}/drive-foundation/tools/flashtools/flashing_kernel/kernel/t23x
Copy the flashing kernel DTB file with the following command:
t23x:
cp ${PWD}/out-t234-linux/out/arch/arm64/boot/dts/nvidia/tegra234-
<board>-<sku>-<rev>-*flashing*-base.dtb ${NV_WORKSPACE}/drive-foundation/
tools/flashtools/flash/t23x/rcmfirmware