diff options
author | Nathan Rossi <nathan@nathanrossi.com> | 2015-11-26 20:03:39 +1000 |
---|---|---|
committer | Nathan Rossi <nathan@nathanrossi.com> | 2015-11-26 20:03:39 +1000 |
commit | e95274e56ff441c1f4cf45ba791ab16166f05bf8 (patch) | |
tree | bdacd18e85f828746a4a0ae68a56136d0599aafa | |
parent | d9d299cd58cdfe3d2c2eb6c643d74d6f511858ec (diff) | |
download | meta-xilinx-e95274e56ff441c1f4cf45ba791ab16166f05bf8.tar.gz |
Fix up UBOOT_BINARY for Zynq and setup SPL to load correctly
u-boot-xlnx 'xilinx-v2015.2' (fixed in newer versions) incorrectly sets
the SPL image to load as 'u-boot-dtb.img' despite the images being built
having embedded device trees (OF_EMBED=y). This change fixes this up so that
there are no hacks to the u-boot recipes and no overrides to use the
incorrectly named U-Boot image file.
Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
4 files changed, 29 insertions, 14 deletions
diff --git a/conf/machine/include/machine-xilinx-default.inc b/conf/machine/include/machine-xilinx-default.inc index 054a2e18..15f85fed 100644 --- a/conf/machine/include/machine-xilinx-default.inc +++ b/conf/machine/include/machine-xilinx-default.inc | |||
@@ -23,7 +23,6 @@ PREFERRED_PROVIDER_virtual/bootloader ??= "${XILINX_DEFAULT_UBOOT}" | |||
23 | UBOOT_SUFFIX ?= "img" | 23 | UBOOT_SUFFIX ?= "img" |
24 | UBOOT_SUFFIX_zynqmp ?= "bin" | 24 | UBOOT_SUFFIX_zynqmp ?= "bin" |
25 | UBOOT_BINARY ?= "u-boot.${UBOOT_SUFFIX}" | 25 | UBOOT_BINARY ?= "u-boot.${UBOOT_SUFFIX}" |
26 | UBOOT_BINARY_zynq ?= "u-boot-dtb.${UBOOT_SUFFIX}" | ||
27 | UBOOT_ELF ?= "u-boot" | 26 | UBOOT_ELF ?= "u-boot" |
28 | UBOOT_ELF_aarch64 ?= "u-boot.elf" | 27 | UBOOT_ELF_aarch64 ?= "u-boot.elf" |
29 | 28 | ||
diff --git a/recipes-bsp/u-boot/u-boot-xlnx-dev.bb b/recipes-bsp/u-boot/u-boot-xlnx-dev.bb index 59dd5a3e..9fa22fed 100644 --- a/recipes-bsp/u-boot/u-boot-xlnx-dev.bb +++ b/recipes-bsp/u-boot/u-boot-xlnx-dev.bb | |||
@@ -25,9 +25,3 @@ HAS_PS7INIT ?= " \ | |||
25 | zynq_zc706_config \ | 25 | zynq_zc706_config \ |
26 | " | 26 | " |
27 | 27 | ||
28 | do_compile_append() { | ||
29 | # link u-boot-dtb.img to u-boot.img. | ||
30 | if [ ! -e ${B}/u-boot-dtb.img ]; then | ||
31 | ln -sf u-boot.img ${B}/u-boot-dtb.img | ||
32 | fi | ||
33 | } | ||
diff --git a/recipes-bsp/u-boot/u-boot-xlnx/ARM-zynq-Fix-up-the-target-file-name-for-u-boot.patch b/recipes-bsp/u-boot/u-boot-xlnx/ARM-zynq-Fix-up-the-target-file-name-for-u-boot.patch new file mode 100644 index 00000000..2ab6fdd3 --- /dev/null +++ b/recipes-bsp/u-boot/u-boot-xlnx/ARM-zynq-Fix-up-the-target-file-name-for-u-boot.patch | |||
@@ -0,0 +1,27 @@ | |||
1 | From: Nathan Rossi <nathan@nathanrossi.com> | ||
2 | Subject: [PATCH] ARM: zynq: Fix up the target file name for u-boot | ||
3 | |||
4 | This should be 'u-boot.img' because all zynq configs are OF_EMBED. | ||
5 | |||
6 | Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> | ||
7 | Upstream-Status: Configuration [mirror upstream...] | ||
8 | --- | ||
9 | include/configs/zynq-common.h | 2 +- | ||
10 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
11 | |||
12 | diff --git a/include/configs/zynq-common.h b/include/configs/zynq-common.h | ||
13 | index e5f2fc5..10c9f18 100644 | ||
14 | --- a/include/configs/zynq-common.h | ||
15 | +++ b/include/configs/zynq-common.h | ||
16 | @@ -501,7 +501,7 @@ | ||
17 | #define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1 | ||
18 | #define CONFIG_SPL_LIBDISK_SUPPORT | ||
19 | #define CONFIG_SPL_FAT_SUPPORT | ||
20 | -#define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot-dtb.img" | ||
21 | +#define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot.img" | ||
22 | #endif | ||
23 | |||
24 | /* Disable dcache for SPL just for sure */ | ||
25 | -- | ||
26 | 2.6.2 | ||
27 | |||
diff --git a/recipes-bsp/u-boot/u-boot-xlnx_2015.04.bb b/recipes-bsp/u-boot/u-boot-xlnx_2015.04.bb index 6bf9ba9a..0bcbffd8 100644 --- a/recipes-bsp/u-boot/u-boot-xlnx_2015.04.bb +++ b/recipes-bsp/u-boot/u-boot-xlnx_2015.04.bb | |||
@@ -2,11 +2,13 @@ include u-boot-xlnx.inc | |||
2 | include u-boot-extra.inc | 2 | include u-boot-extra.inc |
3 | include u-boot-spl-zynq-init.inc | 3 | include u-boot-spl-zynq-init.inc |
4 | 4 | ||
5 | # this matches u-boot-xlnx 'xilinx-v2015.2' release tag | ||
5 | SRCREV = "1160fbcc619f23bf87cde01ed651566474e17eb9" | 6 | SRCREV = "1160fbcc619f23bf87cde01ed651566474e17eb9" |
6 | PV = "v2015.04${XILINX_EXTENSION}+git${SRCPV}" | 7 | PV = "v2015.04${XILINX_EXTENSION}+git${SRCPV}" |
7 | 8 | ||
8 | FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot-xlnx:" | 9 | FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot-xlnx:" |
9 | SRC_URI += " \ | 10 | SRC_URI += " \ |
11 | file://ARM-zynq-Fix-up-the-target-file-name-for-u-boot.patch \ | ||
10 | file://zynq-Add-Zynq-PicoZed-board-support.patch \ | 12 | file://zynq-Add-Zynq-PicoZed-board-support.patch \ |
11 | file://microblaze-Fix-EMAC-Lite-initialization.patch \ | 13 | file://microblaze-Fix-EMAC-Lite-initialization.patch \ |
12 | file://microblaze-generic_defconfig-Disable-configs.patch \ | 14 | file://microblaze-generic_defconfig-Disable-configs.patch \ |
@@ -26,10 +28,3 @@ SRC_URI_append_zedboard-zynq7 = " file://uEnv.txt" | |||
26 | UBOOT_MACHINE_zc702-zynq7 = "zynq_zc70x_config" | 28 | UBOOT_MACHINE_zc702-zynq7 = "zynq_zc70x_config" |
27 | UBOOT_MACHINE_zc706-zynq7 = "zynq_zc70x_config" | 29 | UBOOT_MACHINE_zc706-zynq7 = "zynq_zc70x_config" |
28 | 30 | ||
29 | do_compile_append() { | ||
30 | # link u-boot-dtb.img to u-boot.img. | ||
31 | if [ ! -e ${B}/u-boot-dtb.img ]; then | ||
32 | ln -sf u-boot.img ${B}/u-boot-dtb.img | ||
33 | fi | ||
34 | } | ||
35 | |||