diff options
author | Tom Rini <trini@konsulko.com> | 2020-01-16 09:45:40 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-01-16 09:45:40 -0500 |
commit | 92329e2413f444d1edf29bab66aefccfd782e0a7 (patch) | |
tree | f8d5b354b1f228a5258ba01ca801b8e3a5d31792 /board/xilinx/common/board.c | |
parent | f47704d4ae494ebc8a25c95202e548ea32f98955 (diff) | |
parent | ddb55ff8a66dabe3365735eff9f901bb259c223f (diff) |
Merge tag 'xilinx-for-v2020.04' of https://gitlab.denx.de/u-boot/custodians/u-boot-microblaze
Xilinx/FPGA changes for v2020.04
ARM64:
- Add INIT_SPL_RELATIVE dependency
SPL:
- FIT image fix
- Enable customization of bl2_plat_get_bl31_params()
Pytest:
- Add test for octal/hex conversions
Microblaze:
- Fix manual relocation for one SPI instance
Nand:
- Convert zynq/zynqmp drivers to DM
Xilinx:
- Enable boot script location via Kconfig
- Support OF_SEPARATE in board FDT selection
- Remove low level uart setup it is done later by code
- Add support for DEVICE_TREE variable passing for SPL
Zynq:
- Enable jtag boot mode via distro boot
- Removing unused baseaddresses from hardware.h
- DT fixups
ZynqMP:
- Fix emmc boot sequence
- Simplify spl logic around bss and board_init_r()
- Support psu_post_config_data() calling
- Tune mini-nand DTS
- Fix psu wiring for a2197 boards
- Add runtime MMC device boot order filling in spl
- Clear ATF handoff handling with custom bl2_plat_get_bl31_params()
- Add support u-boot.its generation
- Use single image configuration for all platforms
- Enable PANIC_HANG via Kconfig
- DT fixups
- Firmware fixes
- Add support for zcu208 and zcu1285
Versal:
- Fix emmc boot sequence
- Enable board_late_init() by default
Diffstat (limited to 'board/xilinx/common/board.c')
-rw-r--r-- | board/xilinx/common/board.c | 31 |
1 files changed, 24 insertions, 7 deletions
diff --git a/board/xilinx/common/board.c b/board/xilinx/common/board.c index 1c28263cb8..ae5fe2729f 100644 --- a/board/xilinx/common/board.c +++ b/board/xilinx/common/board.c @@ -5,6 +5,7 @@ */ #include <common.h> +#include <asm/sections.h> #include <dm/uclass.h> #include <i2c.h> @@ -37,16 +38,32 @@ int zynq_board_read_rom_ethaddr(unsigned char *ethaddr) return ret; } -#if defined(CONFIG_OF_BOARD) +#if defined(CONFIG_OF_BOARD) || defined(CONFIG_OF_SEPARATE) void *board_fdt_blob_setup(void) { - static void *fw_dtb = (void *)CONFIG_XILINX_OF_BOARD_DTB_ADDR; + static void *fdt_blob = (void *)CONFIG_XILINX_OF_BOARD_DTB_ADDR; - if (fdt_magic(fw_dtb) != FDT_MAGIC) { - printf("DTB is not passed via %p\n", fw_dtb); - return NULL; - } + if (fdt_magic(fdt_blob) == FDT_MAGIC) + return fdt_blob; - return fw_dtb; + debug("DTB is not passed via %p\n", fdt_blob); + +#ifdef CONFIG_SPL_BUILD + /* FDT is at end of BSS unless it is in a different memory region */ + if (IS_ENABLED(CONFIG_SPL_SEPARATE_BSS)) + fdt_blob = (ulong *)&_image_binary_end; + else + fdt_blob = (ulong *)&__bss_end; +#else + /* FDT is at end of image */ + fdt_blob = (ulong *)&_end; +#endif + + if (fdt_magic(fdt_blob) == FDT_MAGIC) + return fdt_blob; + + debug("DTB is also not passed via %p\n", fdt_blob); + + return NULL; } #endif |