[U-Boot] [PATCH] da850: Add instructions to copy AIS image to NAND

Sekhar Nori nsekhar at ti.com
Fri Mar 17 10:20:13 UTC 2017


On Thursday 16 March 2017 04:02 PM, Axel Haslam wrote:
> Add instructions to write an AIS image to NAND
> by using the u-boot nand tools.
> 
> Signed-off-by: Axel Haslam <ahaslam at baylibre.com>
> ---
>  board/davinci/da8xxevm/README.da850 | 22 ++++++++++++++++++++++
>  1 file changed, 22 insertions(+)
> 
> diff --git a/board/davinci/da8xxevm/README.da850 b/board/davinci/da8xxevm/README.da850
> index 29cb4ec..81b7b58 100644
> --- a/board/davinci/da8xxevm/README.da850
> +++ b/board/davinci/da8xxevm/README.da850
> @@ -47,6 +47,28 @@ U-Boot > sf erase 0 +320000
>  U-Boot > tftp u-boot.ais
>  U-Boot > sf write c0700000 0 $filesize
>  
> +Flashing the images to NAND
> +===========================
> +The AIS image can be written to NAND using the u-boot "nand"
> +commands.
> +
> +Example:
> +
> +The OMAPL138_LCDK requires the AIS image to be written to block 1 of
> +the NAND flash.
> +
> + 1 - Find out the block size using "nand info"
> + 2 - Download the AIS image to memory
> + 3 - Write the AIS image form memory to the first block
> +
> +In the case of the LCDK:
> +  U-Boot > nand info
> +      Erase size    131072 b (0x20000)
> +  U-Boot > tftp u-boot.ais
> +      Load address: 0xc0700000
> +      Bytes transferred = 477448 (74908 hex)

> +  U-Boot > nand write 0xc0700000 0x20000 0x75000

Need to erase nand before this step.

Also, if mtdparts are defined, the steps can be as simple as

U-Boot > nand erase.part NAND.u-boot.ais
U-Boot > tftp u-boot.ais
U-Boot > nand write 0xc0700000 NAND.u-boot.ais

No need to find the erase size or doing manual of filesize to next erase
block boundary.

Thanks,
Sekhar


More information about the U-Boot mailing list