summaryrefslogtreecommitdiffstats
path: root/board/samsung/common/bootscripts/bootzimg.cmd
diff options
context:
space:
mode:
authorPrzemyslaw Marczak <p.marczak@samsung.com>2015-05-22 18:14:28 +0200
committerLukasz Majewski <l.majewski@samsung.com>2015-06-08 15:26:11 +0200
commit2911bd1858d11308164b0b33de4ea0e8994d3edf (patch)
treeb6540065abe9feb03e340547c8c4b9d4aba71dd2 /board/samsung/common/bootscripts/bootzimg.cmd
parent2d4a9b2ce724cd978ed42e8d72d049c54f7e6aff (diff)
downloadblackbird-obmc-uboot-2911bd1858d11308164b0b33de4ea0e8994d3edf.tar.gz
blackbird-obmc-uboot-2911bd1858d11308164b0b33de4ea0e8994d3edf.zip
samsung: common: add example boot scripts
This commit adds example scripts of boot.scr: - bootzimg.cmd - check if dtb exists and boot zImage - autoboot.cmd - check which image exists: Image.itb, zImage or uImage and optionally load fdt file for u/zImage The blank spaces are added to improve readability and can be removed before use mkimage. Required U-Boot environment variables: $boardname, $fdtfile, $console, $mmcbootdev, $mmcbootpart, $mmcrootdev, $mmcrootpart, $rootfstype. Making boot.scr from file.cmd: mkimage -C none -A arm -T script -d file.cmd boot.scr The Odroid XU3 default environment is ready for those boot scripts and the right script can be loaded by DFU. Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com> Cc: Minkyu Kang <mk7.kang@samsung.com>
Diffstat (limited to 'board/samsung/common/bootscripts/bootzimg.cmd')
-rw-r--r--board/samsung/common/bootscripts/bootzimg.cmd10
1 files changed, 10 insertions, 0 deletions
diff --git a/board/samsung/common/bootscripts/bootzimg.cmd b/board/samsung/common/bootscripts/bootzimg.cmd
new file mode 100644
index 0000000000..2fb4c163a7
--- /dev/null
+++ b/board/samsung/common/bootscripts/bootzimg.cmd
@@ -0,0 +1,10 @@
+setenv kernelname zImage;
+setenv boot_kernel "setenv bootargs \"${console} root=/dev/mmcblk${mmcrootdev}p${mmcrootpart} rootfstype=${rootfstype} rootwait ${opts}\";
+load mmc ${mmcbootdev}:${mmcbootpart} 0x40007FC0 '${kernelname}';
+if load mmc ${mmcbootdev}:${mmcbootpart} 40800000 ${fdtfile}; then
+ bootz 0x40007FC0 - 40800000;
+else
+ echo Warning! Booting without DTB: '${fdtfile}'!;
+ bootz 0x40007FC0 -;
+fi;"
+run boot_kernel; \ No newline at end of file
OpenPOWER on IntegriCloud