may I know which JetPack release you’re working with.
please refer to [Release 28.2 Development Guide]-> Flash Script Usage, you could enable -k options and specify the partition-ID to have partial update.
for example,
1)We’re working with JetPack 3.3 and L4T 28.2
2)I use a bash script to flash my TegraTx1, and the script is;
#!/bin/bash
export DEVDIR=/home/burak/JetPack/64_TX1/Linux_for_Tegra
export CROSS_COMPILE=/usr/local/gcc-linaro-5.3-2016.02-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-
export CROSS32CC=/usr/local/gcc-linaro-5.3-2016.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc
export KERNEL_MODULES_OUT=$DEVDIR/images/modules
export TEGRA_KERNEL_OUT=$DEVDIR/images
export ARCH=arm64
cd $DEVDIR/sources/kernel/kernel-4.4
make mrproper
make O=$TEGRA_KERNEL_OUT tegra21_defconfig -j6
make O=$TEGRA_KERNEL_OUT menuconfig -j6
sleep 5
make O=$TEGRA_KERNEL_OUT zImage -j6
make O=$TEGRA_KERNEL_OUT dtbs -j6
make O=$TEGRA_KERNEL_OUT modules -j6
make O=$TEGRA_KERNEL_OUT modules_install INSTALL_MOD_PATH=$KERNEL_MODULES_OUT -j6
export KERNEL_MODULES_NAME=4.4.38+
cd $DEVDIR/images/modules/lib/modules/$KERNEL_MODULES_NAME
rm build source
cd $DEVDIR/images/modules/
tar -cjf kernel_supplements.tbz2 *
mv kernel_supplements.tbz2 $DEVDIR/images/packages
cd $DEVDIR/kernel
tar -xf kernel_headers.tbz2
mv $KERNEL_HEADERS_NAME linux-headers-$KERNEL_MODULES_NAME
tar -cjf kernel_headers_custom.tbz2 linux-headers-$KERNEL_MODULES_NAME
mv kernel_headers_custom.tbz2 $DEVDIR/images/packages
sudo rm -rf linux-headers-$KERNEL_MODULES_NAME
cp $DEVDIR/images/arch/arm64/boot/dts/tegra210-jetson-tx1-p2597-2180-a01-devkit.dtb $DEVDIR/kernel/dtb
cd $DEVDIR/images
cp -rf arch/arm64/boot/Image arch/arm64/boot/zImage packages/kernel_supplements.tbz2 $DEVDIR/kernel/
cp -rf packages/kernel_headers_custom.tbz2 $DEVDIR/kernel/kernel_headers.tbz2
cd $DEVDIR/
sudo ./apply_binaries.sh
//Up to here, it's the same. I dont touch it.
//I uncomment one of these to choose the flashing what I want.
#sudo ./flash.sh jetson-tx1 mmcblk0p1 //Choose this if you want to flash Kernel+DT
./flash.sh -r -k LNX jetson-tx1 mmcblk0p1 //Choose this if you want to flash only kernel
#./flash.sh -r -k DTB jetson-tx1 mmcblk0p1 //Choose this if you want to flash only DTB
It works like a charm when flashing Kernel+DT. It works when flashing only DT. But it doesnt work when I try to flash only the kernel image.
could you please have an alternative way to replace /boot/Image with your customize kernel image.
you should also perform warm-reboot to check if the change works.
thanks
Can’t I just flash with the script over micro-usb in recovery mode without flashing rootfs?
Because sometimes the kernel just crashes, and I won’t be able to copy the Image file to /boot/ then. What can I do when the kernel crashes, and Ubuntu fails to boot? I will not be able to replace kernel that way.
So this method will not be benefical for me that much, although works.
Basically, I need this to work, but I failed to make it work.
Eventhough the script tells that the [LNX] flash is succesfull, I can’t see the changes I make, so in reality it’s not succesfull.
Is this R28.2 (see “head -n 1 /etc/nv_tegra_release”)?
Can you verify that on the Jetson the sha1sum of “/boot/Image” on the TX1 matches that of the Image you compiled? Can you verify this same checksum on the host at the “Linux_for_Tegra/rootfs/boot/Image” location?
since U‑Boot is required for Jetson-TX1, and it’s also a default bootloader for Jetson TX2.
the image flashed to the kernel partition (LNX) is actually a U‑Boot image.
in addition, U‑Boot loads the Linux kernel from /boot/Image in root file system.
hence, that’s why “‑k kernel” options not works as expect.
you may update /boot/Image to takes effect, shown two methods as below for your reference.
Modify /boot/extlinux/extlinux.conf to add a new boot entry.
Connect the Jetson device’s recovery USB port to your host. enter below command at the U‑Boot command prompt: ums 0 mmc 1
this connects eMMC to the host as a set of USB mass storage devices. you then can copy your custom kernel to /boot/Image directly.
thanks
Device tree is now a signed partition and not a file. Boot stages prior to U-Boot required the device tree, and those stages cannot read ext4. There is an exception for older releases.
sine you’re working with l4t-r28.2, which has enable encrypt process in the bootloader.
cboot would add some key entries before passing to u-boot.
you’re still able to remote update the device tree partition if you had signed the dtb files locally.
you might also refer to Topic 1042852 for the discussion of device tree partition need an signed DTB.
thanks