diff options
author | T Karthik Reddy | 2020-12-17 03:15:55 -0700 |
---|---|---|
committer | Michal Simek | 2021-01-04 10:51:27 +0100 |
commit | 5766429b7c7b71f5cc333b727c569809d5c82d34 (patch) | |
tree | fc6a8beb7f59ecbdd49500ba3d749100c1abb5ea | |
parent | 2d381d2fe2d202694d0b201ee81034c486028641 (diff) |
microblaze: Set script_offset_nor env variable
Set script_offset_nor env variable using CONFIG_BOOT_SCRIPT_OFFSET
and nor flash start address to keep bootscript offset configurable.
Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
-rw-r--r-- | board/xilinx/microblaze-generic/microblaze-generic.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/board/xilinx/microblaze-generic/microblaze-generic.c b/board/xilinx/microblaze-generic/microblaze-generic.c index e5909997690..d4095c07c1e 100644 --- a/board/xilinx/microblaze-generic/microblaze-generic.c +++ b/board/xilinx/microblaze-generic/microblaze-generic.c @@ -67,7 +67,10 @@ int board_late_init(void) status |= env_set_hex("ramdisk_addr_r", gd->ram_base + SZ_32M + SZ_4M + SZ_2M); - + if (IS_ENABLED(CONFIG_MTD_NOR_FLASH)) + status |= env_set_hex("script_offset_nor", + gd->bd->bi_flashstart + + CONFIG_BOOT_SCRIPT_OFFSET); if (status) printf("%s: Saving run time variables FAILED\n", __func__); |