summaryrefslogtreecommitdiff
path: root/include/configs/mx28evk.h
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2013-12-16 20:44:03 -0200
committerStefano Babic <sbabic@denx.de>2014-01-03 15:44:05 +0100
commit8ae269d41e2551439284d2c837c476ae4a357032 (patch)
tree464b63449893ea73792a9616268a980133cc66b7 /include/configs/mx28evk.h
parent09308e8e4953886951a3b5921d6944584e997dc0 (diff)
downloadu-boot-imx-8ae269d41e2551439284d2c837c476ae4a357032.zip
u-boot-imx-8ae269d41e2551439284d2c837c476ae4a357032.tar.gz
u-boot-imx-8ae269d41e2551439284d2c837c476ae4a357032.tar.bz2
mx28evk: Extend environment to easy write of NAND system
This adds following new targets: - update_nand_kernel - update_nand_fdt - update_nand_filesystem and to avoid confusion, the 'update_nand_full' has been renamed to 'update_nand_firmware_full'. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Diffstat (limited to 'include/configs/mx28evk.h')
-rw-r--r--include/configs/mx28evk.h35
1 files changed, 34 insertions, 1 deletions
diff --git a/include/configs/mx28evk.h b/include/configs/mx28evk.h
index 6c9fa00..4fd67eb 100644
--- a/include/configs/mx28evk.h
+++ b/include/configs/mx28evk.h
@@ -160,6 +160,7 @@
/* Extra Environment */
#define CONFIG_EXTRA_ENV_SETTINGS \
+ "ubifs_file=filesystem.ubifs\0" \
"update_nand_full_filename=u-boot.nand\0" \
"update_nand_firmware_filename=u-boot.sb\0" \
"update_nand_firmware_maxsz=0x100000\0" \
@@ -170,7 +171,7 @@
"nand info ; " \
"setexpr fcb_sz ${update_nand_stride} * ${update_nand_count};" \
"setexpr update_nand_fcb ${fcb_sz} * ${nand_writesize}\0" \
- "update_nand_full=" /* Update FCB, DBBT and FW */ \
+ "update_nand_firmware_full=" /* Update FCB, DBBT and FW */ \
"if tftp ${update_nand_full_filename} ; then " \
"run update_nand_get_fcb_size ; " \
"nand scrub -y 0x0 ${filesize} ; " \
@@ -189,6 +190,38 @@
"nand write ${loadaddr} ${fcb_sz} ${filesize} ; " \
"nand write ${loadaddr} ${fw_off} ${filesize} ; " \
"fi\0" \
+ "update_nand_kernel=" /* Update kernel */ \
+ "mtdparts default; " \
+ "nand erase.part kernel; " \
+ "if test ${ip_dyn} = yes; then " \
+ "setenv get_cmd dhcp; " \
+ "else " \
+ "setenv get_cmd tftp; " \
+ "fi; " \
+ "${get_cmd} ${uimage}; " \
+ "nand write ${loadaddr} kernel ${filesize}\0" \
+ "update_nand_fdt=" /* Update fdt */ \
+ "mtdparts default; " \
+ "nand erase.part fdt; " \
+ "if test ${ip_dyn} = yes; then " \
+ "setenv get_cmd dhcp; " \
+ "else " \
+ "setenv get_cmd tftp; " \
+ "fi; " \
+ "${get_cmd} ${fdt_file}; " \
+ "nand write ${loadaddr} fdt ${filesize}\0" \
+ "update_nand_filesystem=" /* Update filesystem */ \
+ "mtdparts default; " \
+ "nand erase.part filesystem; " \
+ "if test ${ip_dyn} = yes; then " \
+ "setenv get_cmd dhcp; " \
+ "else " \
+ "setenv get_cmd tftp; " \
+ "fi; " \
+ "${get_cmd} ${ubifs_file}; " \
+ "ubi part filesystem; " \
+ "ubi create filesystem; " \
+ "ubi write ${loadaddr} filesystem ${filesize}\0" \
"nandargs=setenv bootargs console=${console_mainline},${baudrate} " \
"rootfstype=ubifs ubi.mtd=6 root=ubi0_0 ${mtdparts}\0" \
"nandboot=" /* Boot from NAND */ \