From fc71c5f09bc8bd60e2e8e09bdb57b3143bc9d22f Mon Sep 17 00:00:00 2001 From: Jonathan Herman Date: Thu, 17 Jan 2013 13:15:24 -0800 Subject: Added Tegra kernel install scripts. --- tegra-install-kernel.sh | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100755 tegra-install-kernel.sh (limited to 'tegra-install-kernel.sh') diff --git a/tegra-install-kernel.sh b/tegra-install-kernel.sh new file mode 100755 index 0000000..c48f8b0 --- /dev/null +++ b/tegra-install-kernel.sh @@ -0,0 +1,44 @@ +#!/bin/sh + +if [ $# -ne 1 ] ; then + error "Usage: `basename $0` " +fi + +. $(dirname $0)/arm-installer-common.sh + +LOAD_ADDR=0x81008000 +ENTRY_POINT=0x81008000 + +USB_PART=/dev/sdb1 +TMP_MOUNT=$(mktemp -d) +# Use default boot image name on Tegra instead of creating a new boot script +# The tegra cannot install a new boot script without manual labor +BOOT_IMAGE=vmlinux.uimg + +KVERSION=$(getversion) +CONFIG_FILE="config-$KVERSION" + +fetchfiles + +mkuboot + +moveconfig + +echo "Mounting USB partition ..." >&2 +sudo mount $USB_PART $TMP_MOUNT +echo "done." >&2 + +if [ ! -d "$TMP_MOUNT/boot" ]; then + sudo rm -f "$TMP_MOUNT/boot" + sudo mkdir "$TMP_MOUNT/boot" +fi +sudo cp $out_image "$TMP_MOUNT/boot/$BOOT_IMAGE" + +echo "Unmounting USB partition ..." >&2 +sudo umount $TMP_MOUNT +echo "done." >&2 + +rm_tmp_files +rm -rf $TMP_MOUNT + +echo "All done!" >&2 -- cgit v1.2.2