summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr.bb10
-rw-r--r--meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.generic46
2 files changed, 21 insertions, 35 deletions
diff --git a/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr.bb b/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr.bb
index fa92f660..bc4eb04a 100644
--- a/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr.bb
+++ b/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr.bb
@@ -142,15 +142,13 @@ QSPI_KERNEL_IMAGE_versal ?= "image.ub"
142 142
143NAND_KERNEL_IMAGE ?= "image.ub" 143NAND_KERNEL_IMAGE ?= "image.ub"
144 144
145QSPI_FIT_IMAGE_LOAD_ADDRESS ?= "${@append_baseaddr(d,d.getVar('QSPI_FIT_IMAGE_OFFSET'))}" 145QSPI_FIT_IMAGE_OFFSET ?= "0x1080000"
146QSPI_FIT_IMAGE_OFFSET ?= "0x10000000"
147QSPI_FIT_IMAGE_SIZE ?= "0x6400000" 146QSPI_FIT_IMAGE_SIZE ?= "0x6400000"
148QSPI_FIT_IMAGE_SIZE_zynqmpdr ?= "0x3F00000" 147QSPI_FIT_IMAGE_SIZE_zynqmpdr ?= "0x3F00000"
149QSPI_FIT_IMAGE_SIZE_zynq ?= "0xF00000" 148QSPI_FIT_IMAGE_SIZE_zynq ?= "0xF00000"
150QSPI_FIT_IMAGE_SIZE_microblaze ?= "0xF00000" 149QSPI_FIT_IMAGE_SIZE_microblaze ?= "0xF00000"
151 150
152NAND_FIT_IMAGE_LOAD_ADDRESS ?= "${@append_baseaddr(d,d.getVar('NAND_FIT_IMAGE_OFFSET'))}" 151NAND_FIT_IMAGE_OFFSET ?= "0x1080000"
153NAND_FIT_IMAGE_OFFSET ?= "0x10000000"
154NAND_FIT_IMAGE_SIZE ?= "0x6400000" 152NAND_FIT_IMAGE_SIZE ?= "0x6400000"
155 153
156SDBOOTDEV ?= "0" 154SDBOOTDEV ?= "0"
@@ -222,10 +220,10 @@ do_compile() {
222 -e 's/@@KERNEL_IMAGE@@/${KERNEL_IMAGE}/' \ 220 -e 's/@@KERNEL_IMAGE@@/${KERNEL_IMAGE}/' \
223 -e 's/@@QSPI_KERNEL_IMAGE@@/${QSPI_KERNEL_IMAGE}/' \ 221 -e 's/@@QSPI_KERNEL_IMAGE@@/${QSPI_KERNEL_IMAGE}/' \
224 -e 's/@@NAND_KERNEL_IMAGE@@/${NAND_KERNEL_IMAGE}/' \ 222 -e 's/@@NAND_KERNEL_IMAGE@@/${NAND_KERNEL_IMAGE}/' \
225 -e 's/@@QSPI_FIT_IMAGE_LOAD_ADDRESS@@/${QSPI_FIT_IMAGE_LOAD_ADDRESS}/' \
226 -e 's/@@FIT_IMAGE_LOAD_ADDRESS@@/${FIT_IMAGE_LOAD_ADDRESS}/' \ 223 -e 's/@@FIT_IMAGE_LOAD_ADDRESS@@/${FIT_IMAGE_LOAD_ADDRESS}/' \
224 -e 's/@@QSPI_FIT_IMAGE_OFFSET@@/${QSPI_FIT_IMAGE_OFFSET}/' \
227 -e 's/@@QSPI_FIT_IMAGE_SIZE@@/${QSPI_FIT_IMAGE_SIZE}/' \ 225 -e 's/@@QSPI_FIT_IMAGE_SIZE@@/${QSPI_FIT_IMAGE_SIZE}/' \
228 -e 's/@@NAND_FIT_IMAGE_LOAD_ADDRESS@@/${NAND_FIT_IMAGE_LOAD_ADDRESS}/' \ 226 -e 's/@@NAND_FIT_IMAGE_OFFSET@@/${NAND_FIT_IMAGE_OFFSET}/' \
229 -e 's/@@NAND_FIT_IMAGE_SIZE@@/${NAND_FIT_IMAGE_SIZE}/' \ 227 -e 's/@@NAND_FIT_IMAGE_SIZE@@/${NAND_FIT_IMAGE_SIZE}/' \
230 -e 's/@@FIT_IMAGE@@/${FIT_IMAGE}/' \ 228 -e 's/@@FIT_IMAGE@@/${FIT_IMAGE}/' \
231 -e 's/@@PRE_BOOTENV@@/${PRE_BOOTENV}/' \ 229 -e 's/@@PRE_BOOTENV@@/${PRE_BOOTENV}/' \
diff --git a/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.generic b/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.generic
index cbec5cfd..919d20d8 100644
--- a/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.generic
+++ b/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.generic
@@ -10,7 +10,6 @@ do
10 echo "Trying to load boot images from ${boot_target}" 10 echo "Trying to load boot images from ${boot_target}"
11 if test "${boot_target}" = "jtag" ; then 11 if test "${boot_target}" = "jtag" ; then
12 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@ 12 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@
13 exit;
14 fi 13 fi
15 if test "${boot_target}" = "mmc0" || test "${boot_target}" = "mmc1" ; then 14 if test "${boot_target}" = "mmc0" || test "${boot_target}" = "mmc1" ; then
16 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@UENV_TEXTFILE@@; then 15 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@UENV_TEXTFILE@@; then
@@ -25,7 +24,6 @@ do
25 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@FIT_IMAGE@@; then 24 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@FIT_IMAGE@@; then
26 fatload ${devtype} ${devnum}:${distro_bootpart} @@FIT_IMAGE_LOAD_ADDRESS@@ @@FIT_IMAGE@@; 25 fatload ${devtype} ${devnum}:${distro_bootpart} @@FIT_IMAGE_LOAD_ADDRESS@@ @@FIT_IMAGE@@;
27 bootm @@FIT_IMAGE_LOAD_ADDRESS@@; 26 bootm @@FIT_IMAGE_LOAD_ADDRESS@@;
28 exit;
29 fi 27 fi
30 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@KERNEL_IMAGE@@; then 28 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@KERNEL_IMAGE@@; then
31 fatload ${devtype} ${devnum}:${distro_bootpart} @@KERNEL_LOAD_ADDRESS@@ @@KERNEL_IMAGE@@;; 29 fatload ${devtype} ${devnum}:${distro_bootpart} @@KERNEL_LOAD_ADDRESS@@ @@KERNEL_IMAGE@@;;
@@ -36,43 +34,33 @@ do
36 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@RAMDISK_IMAGE1@@ && test "${skip_tinyramdisk}" != "yes"; then 34 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@RAMDISK_IMAGE1@@ && test "${skip_tinyramdisk}" != "yes"; then
37 fatload ${devtype} ${devnum}:${distro_bootpart} @@RAMDISK_IMAGE_ADDRESS@@ @@RAMDISK_IMAGE1@@; 35 fatload ${devtype} ${devnum}:${distro_bootpart} @@RAMDISK_IMAGE_ADDRESS@@ @@RAMDISK_IMAGE1@@;
38 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@ 36 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@
39 exit;
40 fi 37 fi
41 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@RAMDISK_IMAGE@@ && test "${skip_ramdisk}" != "yes"; then 38 if test -e ${devtype} ${devnum}:${distro_bootpart} /@@RAMDISK_IMAGE@@ && test "${skip_ramdisk}" != "yes"; then
42 fatload ${devtype} ${devnum}:${distro_bootpart} @@RAMDISK_IMAGE_ADDRESS@@ @@RAMDISK_IMAGE@@; 39 fatload ${devtype} ${devnum}:${distro_bootpart} @@RAMDISK_IMAGE_ADDRESS@@ @@RAMDISK_IMAGE@@;
43 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@ 40 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@
44 exit;
45 fi 41 fi
46 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ - @@DEVICETREE_ADDRESS@@ 42 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ - @@DEVICETREE_ADDRESS@@
47 exit;
48 fi 43 fi
49 if test "${boot_target}" = "xspi0" || test "${boot_target}" = "qspi" || test "${boot_target}" = "qspi0"; then 44 if test "${boot_target}" = "xspi0" || test "${boot_target}" = "qspi" || test "${boot_target}" = "qspi0"; then
50 sf probe 0 0 0; 45 sf probe 0 0 0;
51 if test "@@QSPI_KERNEL_IMAGE@@" = "@@FIT_IMAGE@@"; then 46 sf read @@FIT_IMAGE_LOAD_ADDRESS@@ @@QSPI_FIT_IMAGE_OFFSET@@ @@QSPI_FIT_IMAGE_SIZE@@
52 sf read @@QSPI_FIT_IMAGE_LOAD_ADDRESS@@ @@QSPI_KERNEL_OFFSET@@ @@QSPI_FIT_IMAGE_SIZE@@; 47 bootm @@FIT_IMAGE_LOAD_ADDRESS@@;
53 bootm @@QSPI_FIT_IMAGE_LOAD_ADDRESS@@; 48 echo "Booting using Fit image failed"
54 exit; 49
55 fi 50 sf read @@KERNEL_LOAD_ADDRESS@@ @@QSPI_KERNEL_OFFSET@@ @@QSPI_KERNEL_SIZE@@
56 if test "@@QSPI_KERNEL_IMAGE@@" = "@@KERNEL_IMAGE@@"; then 51 sf read @@RAMDISK_IMAGE_ADDRESS@@ @@QSPI_RAMDISK_OFFSET@@ @@QSPI_RAMDISK_SIZE@@
57 sf read @@KERNEL_LOAD_ADDRESS@@ @@QSPI_KERNEL_OFFSET@@ @@QSPI_KERNEL_SIZE@@; 52 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@;
58 sf read @@RAMDISK_IMAGE_ADDRESS@@ @@QSPI_RAMDISK_OFFSET@@ @@QSPI_RAMDISK_SIZE@@ 53 echo "Booting using Separate images failed"
59 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@
60 exit;
61 fi
62 exit;
63 fi 54 fi
64 if test "${boot_target}" = "nand" || test "${boot_target}" = "nand0"; then 55 if test "${boot_target}" = "nand" || test "${boot_target}" = "nand0"; then
65 nand info 56 nand info;
66 if test "@@NAND_KERNEL_IMAGE@@" = "@@FIT_IMAGE@@"; then 57 nand read @@FIT_IMAGE_LOAD_ADDRESS@@ @@NAND_FIT_IMAGE_OFFSET@@ @@NAND_FIT_IMAGE_SIZE@@
67 nand read @@NAND_FIT_IMAGE_LOAD_ADDRESS@@ @@NAND_KERNEL_OFFSET@@ @@NAND_FIT_IMAGE_SIZE@@; 58 bootm @@FIT_IMAGE_LOAD_ADDRESS@@;
68 bootm @@NAND_FIT_IMAGE_LOAD_ADDRESS@@; 59 echo "Booting using Fit image failed"
69 exit; 60
70 fi 61 nand read @@KERNEL_LOAD_ADDRESS@@ @@NAND_KERNEL_OFFSET@@ @@NAND_KERNEL_SIZE@@
71 if test "@@NAND_KERNEL_IMAGE@@" = "@@KERNEL_IMAGE@@"; then 62 nand read @@RAMDISK_IMAGE_ADDRESS@@ @@NAND_RAMDISK_OFFSET@@ @@NAND_RAMDISK_SIZE@@
72 nand read @@KERNEL_LOAD_ADDRESS@@ @@NAND_KERNEL_OFFSET@@ @@NAND_KERNEL_SIZE@@; 63 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@;
73 nand read @@RAMDISK_IMAGE_ADDRESS@@ @@NAND_RAMDISK_OFFSET@@ @@NAND_RAMDISK_SIZE@@; 64 echo "Booting using Separate images failed"
74 @@KERNEL_BOOTCMD@@ @@KERNEL_LOAD_ADDRESS@@ @@RAMDISK_IMAGE_ADDRESS@@ @@DEVICETREE_ADDRESS@@
75 exit;
76 fi
77 fi 65 fi
78done 66done