aboutsummaryrefslogtreecommitdiff
path: root/board/xilinx/zynq/board.c
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2020-07-28 12:45:47 +0200
committerMichal Simek <michal.simek@xilinx.com>2020-08-20 09:49:20 +0200
commit62b96262b6dad1000b1ed2fec8664c2757585061 (patch)
treeb42024e0712e75a580fb07005e4acd79213875fa /board/xilinx/zynq/board.c
parentd5c42ec31b004218666b60ab990c1b56d5b09050 (diff)
downloadu-boot-62b96262b6dad1000b1ed2fec8664c2757585061.zip
u-boot-62b96262b6dad1000b1ed2fec8664c2757585061.tar.gz
u-boot-62b96262b6dad1000b1ed2fec8664c2757585061.tar.bz2
xilinx: Add support for ENV_VARS_UBOOT_RUNTIME_CONFIG
Start to use ENV_VARS_UBOOT_RUNTIME_CONFIG to enable/disable updating variables with run time information. Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'board/xilinx/zynq/board.c')
-rw-r--r--board/xilinx/zynq/board.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/board/xilinx/zynq/board.c b/board/xilinx/zynq/board.c
index 2164eac..7ac069a 100644
--- a/board/xilinx/zynq/board.c
+++ b/board/xilinx/zynq/board.c
@@ -6,6 +6,7 @@
#include <common.h>
#include <init.h>
+#include <log.h>
#include <dm/uclass.h>
#include <env.h>
#include <fdtdec.h>
@@ -33,6 +34,14 @@ int board_late_init(void)
char *new_targets;
char *env_targets;
+ if (!(gd->flags & GD_FLG_ENV_DEFAULT)) {
+ debug("Saved variables - Skipping\n");
+ return 0;
+ }
+
+ if (!CONFIG_IS_ENABLED(ENV_VARS_UBOOT_RUNTIME_CONFIG))
+ return 0;
+
switch ((zynq_slcr_get_boot_mode()) & ZYNQ_BM_MASK) {
case ZYNQ_BM_QSPI:
mode = "qspi";