ARM: UniPhier: add environment variable to update images in NAND

To boot UniPhier boards with the NAND boot mode, two images
(u-boot-spl.bin and u-boot-dtb.img) must be written at the correct
offset addresses.

TFTP downloading is useful to update such images in the NAND device.
We generally do:

  => nand erase 0 0x100000
  => tftpboot u-boot-spl.bin
  => nand write $loadaddr 0 0x10000
  => tftpboot u-boot-dtb.img
  => nand write $loadaddr 0x10000 0xf0000

It is a tedious and error-prone operation.

This commit provides the shorthand:

  => run nandupdate

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
This commit is contained in:
Masahiro Yamada 2015-02-05 14:30:22 +09:00
parent 0e063dff5c
commit 75bc8e85b5
1 changed files with 5 additions and 0 deletions

View File

@ -235,6 +235,11 @@
"image_offset=0x00080000\0" \
"image_size=0x00f00000\0" \
"verify=n\0" \
"nandupdate=nand erase 0 0x100000 &&" \
"tftpboot u-boot-spl.bin &&" \
"nand write $loadaddr 0 0x10000 &&" \
"tftpboot u-boot-dtb.img &&" \
"nand write $loadaddr 0x10000 0xf0000\0" \
"norboot=run add_default_bootargs &&" \
"bootm $image_offset\0" \
"nandboot=run add_default_bootargs &&" \