summaryrefslogtreecommitdiffstats
path: root/defaultenv
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2011-09-25 22:54:09 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2011-09-26 13:22:25 +0200
commit217b9a5052b34b4b25a8e517e25d5bbcbaf182c2 (patch)
tree1a5f7bc92bf7133514e00b1cb08f89ad2370243a /defaultenv
parentcf8af385c759261e4bc89cfad8dab26d8bf07153 (diff)
downloadbarebox-217b9a5052b34b4b25a8e517e25d5bbcbaf182c2.tar.gz
defaultenv: update: add support to update kernel on disk
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'defaultenv')
-rw-r--r--defaultenv/bin/_update_help2
-rw-r--r--defaultenv/bin/update3
2 files changed, 4 insertions, 1 deletions
diff --git a/defaultenv/bin/_update_help b/defaultenv/bin/_update_help
index 98096da..92d6772 100644
--- a/defaultenv/bin/_update_help
+++ b/defaultenv/bin/_update_help
@@ -7,7 +7,7 @@ echo "options"
echo " -c to check the crc32 for the image and flashed one"
echo ""
echo "default mode is tftp"
-echo "type update -t kernel -d <nor|nand> [-m tftp|xmodem] [-f imagename] to update kernel into flash"
+echo "type update -t kernel -d <nor|nand|disk> [-m tftp|xmodem] [-f imagename] to update kernel into flash"
echo "type update -t rootfs -d <nor|nand> [-m tftp|xmodem] [-f imagename] to update rootfs into flash"
echo "type update -t barebox -d <nor|nand> [-m tftp|xmodem] [-f imagename] to update barebox into flash"
echo "type update -t bareboxenv -d <nor|nand> [-m tftp|xmodem] [-f imagename] to update bareboxenv into flash"
diff --git a/defaultenv/bin/update b/defaultenv/bin/update
index 6fd5e4c..39e7591 100644
--- a/defaultenv/bin/update
+++ b/defaultenv/bin/update
@@ -27,6 +27,7 @@ done
if [ x${type} = xkernel ]; then
image=$kernelimage
+ disk_part=$kernel_part
elif [ x${type} = xrootfs ]; then
image=$rootfsimage
type=root
@@ -55,6 +56,8 @@ if [ x${device_type} = xnand ]; then
part=/dev/nand0.${type}.bb
elif [ x${device_type} = xnor ]; then
part=/dev/nor0.${type}
+elif [ x${device_type} = xdisk ]; then
+ part=/dev/${disk_part}
else
. /env/bin/_update_help
exit 1