[U-Boot] [PATCH v3 1/3] board: STiH410-B2260: update environment variable

patrice.chotard at st.com patrice.chotard at st.com
Mon Sep 25 07:14:18 UTC 2017


From: Patrice Chotard <patrice.chotard at st.com>

Update environment variable by updating:
 _ BOOT_TARGET_DEVICE
 _ CONFIGS_BOOTARGS
 _ kernel_addr_r, fdtfile, fdt_addr_r, scriptaddr, fdt_high, intird_high

Signed-off-by: Patrice Chotard <patrice.chotard at st.com>
Reviewed-by: Simon Glass <sjg at chromium.org>
---
v3: none
v2: rebase on v2017.09

 configs/stih410-b2260_defconfig |  2 +-
 include/configs/stih410-b2260.h | 24 +++++++++++++++++++++---
 2 files changed, 22 insertions(+), 4 deletions(-)

diff --git a/configs/stih410-b2260_defconfig b/configs/stih410-b2260_defconfig
index 8fd1ff2..fe3dde3 100644
--- a/configs/stih410-b2260_defconfig
+++ b/configs/stih410-b2260_defconfig
@@ -6,7 +6,7 @@ CONFIG_DISTRO_DEFAULTS=y
 CONFIG_FIT=y
 CONFIG_FIT_VERBOSE=y
 CONFIG_USE_BOOTARGS=y
-CONFIG_BOOTARGS="console=ttyS0,115200 earlyprintk consoleblank=0 ignore_loglevel"
+CONFIG_BOOTARGS="console=ttyAS1,115200 CONSOLE=/dev/ttyAS1 consoleblank=0 root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait mem=992M at 0x40000000 vmalloc=256m"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SYS_PROMPT="stih410-b2260 => "
 CONFIG_FASTBOOT=y
diff --git a/include/configs/stih410-b2260.h b/include/configs/stih410-b2260.h
index 372c083..115488c 100644
--- a/include/configs/stih410-b2260.h
+++ b/include/configs/stih410-b2260.h
@@ -18,10 +18,28 @@
 
 #define CONFIG_SYS_HZ_CLOCK		1000000000	/* 1 GHz */
 
+#include <config_distro_defaults.h>
 /* Environment */
-#define CONFIG_EXTRA_ENV_SETTINGS \
-	"board= B2260" \
-	"load_addr= #CONFIG_SYS_LOAD_ADDR \0"
+
+#define CONFIG_LOADADDR			CONFIG_SYS_LOAD_ADDR
+
+#define CONFIG_ENV_VARS_UBOOT_CONFIG
+
+#define BOOT_TARGET_DEVICES(func) \
+	func(MMC, mmc, 0) \
+	func(USB, usb, 0) \
+	func(DHCP, dhcp, na)
+#include <config_distro_bootcmd.h>
+#define CONFIG_BOOTFILE			"uImage"
+#define CONFIG_EXTRA_ENV_SETTINGS				\
+			"kernel_addr_r=0x40000000\0"		\
+			"fdtfile=stih410-b2260.dtb\0"		\
+			"fdt_addr_r=0x47000000\0"		\
+			"scriptaddr=0x50000000\0"		\
+			"fdt_high=0xffffffffffffffff\0"		\
+			"initrd_high=0xffffffffffffffff\0"	\
+			BOOTENV
+
 
 #define CONFIG_ENV_SIZE 0x4000
 
-- 
1.9.1



More information about the U-Boot mailing list