Building the Flashing Kernel
This topic provides instructions on building the flashing kernel sources.
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
1. Extract the flashing kernel sources using the following commands on the host:
cd <top>/drive-t186ref-foundation_src/kernel
tar xvf drive-oss-t186-flashing_kernel-src.tar.bz2
cd drive-oss-t186-flashing_kernel-src/drive-oss-src
2. Set up the environment macros:
export ARCH=arm64
export CROSS_COMPILE=<top>/toolchains/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-
export LOCALVERSION="-tegra"
3. Create an output directory, and then configure the kernel for the board:
mkdir –p out-t194-linux/out
make -C kernel O=${PWD}/out-t194-linux/out clean
4. Add the following command:
make -C kernel O=${PWD}/out-t194-linux/out tegra_defconfig
5. Build the kernel:
make -C kernel O=${PWD}/out-t194-linux/out –j4
If the above command fails, enter the make command without the j<number> option.
6. Copy the uncompressed kernel image with the following command:
cp ${PWD}/out-t194-linux/out/arch/arm64/boot/Image <top>/drive-t186ref-foundation/tools/host/flashtools/flash/t18x/rcmkernel
7. Copy the flashing kernel DTB file with the following command:
cp ${PWD}/out-t194-linux/out/arch/arm64/boot/dts/tegra194-<board>-<sku>-<rev>-A-flashing-base.dtb <top>/drive-t186ref-foundation/tools/host/flashtools/flash/t18x/rcmkernel
cp ${PWD}/out-t194-linux/out/arch/arm64/boot/dts/tegra194-<board>-<sku>-<rev>-B-flashing-base.dtb <top>/drive-t186ref-foundation/tools/host/flashtools/flash/t18x/rcmkernel
For definitions of the <board>-<sku_id>-<rev>, see the Release Notes.