Michal Simek 24124abe06 arm64: zynqmp: Add support for generic QSPI boot
This patch is enabling support for SPL QSPI boot.

First of all it is necessary to generate atf-spi.ub which is different
format than atf-uboot.ub (this can be made as legacy image too)

ADDR=`arm-xilinx-linux-gnueabi-readelf -a bl31.elf | grep "Entry point
address" | cut -d ':' -f 2 | sed -e 's/^[ \t]*//'`
aarch64-linux-gnu-objcopy -O binary bl31.elf bl31.bin
./tools/mkimage -f auto -A arm64 -T firmware -C none -O u-boot -a $ADDR
-e $ADDR -n "atf1" -E -b arch/arm/dts/zynqmp-zcu102.dtb -d bl31.bin
atf-uboot.ub
./tools/mkimage -A arm64 -T firmware -C none -O u-boot -a $ADDR -e $ADDR
-n "atf-for-qspi" -E -d bl31.bin atf-spi.ub

This patch is using this QSPI layout with offsets:
0 boot.bin
512k atf-ub
640k u-boot.bin
1280k u-boot.img

Which corresponding by writing these images(read from MMC)
mmcinfo
sf probe
load mmc 0 10000000 boot.bin
sf erase 0 +$filesize
sf write 10000000 0 $filesize
load mmc 0 10000000 atf-spi.ub
sf erase 0x80000 +$filesize
sf write 10000000 0x80000 $filesize
load mmc 0 10000000 u-boot.bin
sf erase 0xa0000 +$filesize
sf write 10000000 0xa0000 $filesize
load mmc 0 10000000 u-boot.img
sf erase 0x140000 +$filesize
sf write 10000000 0x140000 $filesize

For testing u-boot running in EL3 you can break atf-spi.ub like this:
sf probe
sf erase 0x80000 +4

Then u-boot.img is executed.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-12-14 20:08:21 +01:00
..
2017-07-03 17:35:28 -04:00
2017-02-08 15:56:28 -05:00
2017-11-28 16:08:52 +01:00
2017-06-05 11:02:29 -04:00
2017-09-16 14:57:44 +08:00
2017-10-02 21:52:18 -04:00
2017-09-15 05:27:47 -06:00
2017-05-11 22:21:27 -04:00
2017-07-28 23:34:39 +02:00
2017-04-13 09:41:10 -04:00
2017-08-17 16:59:55 +09:00
2017-05-15 20:32:12 +02:00
2017-08-16 08:30:24 -04:00
2017-10-02 21:52:18 -04:00
2017-11-07 10:26:27 +01:00
2017-09-03 15:30:35 -04:00
2017-07-23 09:24:47 -04:00
2017-06-12 08:37:55 -04:00
2017-04-14 19:38:57 -06:00
2017-12-07 15:17:00 -05:00
2017-11-28 21:59:30 +01:00
2017-12-04 22:00:00 +09:00
2017-09-20 10:20:00 +02:00
2017-11-28 21:59:30 +01:00
2017-06-12 08:37:55 -04:00
2017-12-07 15:17:00 -05:00
2017-07-28 23:34:07 +02:00
2017-04-10 10:02:03 +08:00
2017-08-17 16:59:55 +09:00
2017-08-23 10:41:58 +02:00
2017-08-16 08:22:18 -04:00
2017-06-01 07:03:16 -06:00
2017-04-12 13:28:27 -04:00
2017-10-01 16:32:51 +02:00
2017-08-24 11:00:47 +08:00
2017-10-04 12:00:19 -04:00