aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--board/xilinx/common/board.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/board/xilinx/common/board.c b/board/xilinx/common/board.c
index 581c88ad49a..eab389d049f 100644
--- a/board/xilinx/common/board.c
+++ b/board/xilinx/common/board.c
@@ -78,11 +78,15 @@ void *board_fdt_blob_setup(void)
int board_late_init_xilinx(void)
{
u32 ret = 0;
+ phys_size_t bootm_size = gd->ram_size;
+
+ if (CONFIG_IS_ENABLED(ARCH_ZYNQ))
+ bootm_size = min(bootm_size, (phys_size_t)(SZ_512M + SZ_256M));
ret |= env_set_hex("script_offset_f", CONFIG_BOOT_SCRIPT_OFFSET);
ret |= env_set_addr("bootm_low", (void *)gd->ram_base);
- ret |= env_set_addr("bootm_size", (void *)gd->ram_size);
+ ret |= env_set_addr("bootm_size", (void *)bootm_size);
if (ret)
printf("%s: Saving run time variables FAILED\n", __func__);