aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Rigby <john.rigby@linaro.org>2012-02-16 08:43:20 -0700
committerJohn Rigby <john.rigby@linaro.org>2012-08-16 10:10:25 -0600
commit8ad68ea09f0cb0a47b6793672a31861174d3e043 (patch)
treeda7ad29dc76da57ecdbb204eef0538eaec1b4c6a
parent392394a665174f9bbf79b318223116d9a77e0b03 (diff)
downloadu-boot-linaro-stable-8ad68ea09f0cb0a47b6793672a31861174d3e043.tar.gz
OMAP4: add preEnv.txt support
Signed-off-by: John Rigby <john.rigby@linaro.org>
-rw-r--r--include/configs/omap4_common.h19
1 files changed, 18 insertions, 1 deletions
diff --git a/include/configs/omap4_common.h b/include/configs/omap4_common.h
index 8fe2b552f..b66c67b66 100644
--- a/include/configs/omap4_common.h
+++ b/include/configs/omap4_common.h
@@ -162,7 +162,12 @@
"loadbootscript=fatload mmc ${mmcdev} ${loadaddr} ${bootscr}\0" \
"bootscript=echo Running bootscript from mmc${mmcdev} ...; " \
"source ${loadaddr}\0" \
- "loadbootenv=fatload mmc ${mmcdev} ${loadaddr} uEnv.txt\0" \
+ "preenv=preEnv.txt\0" \
+ "loadpreenv=fatload mmc ${mmcdev} ${loadaddr} ${preenv}\0" \
+ "importpreenv=echo Importing preboot environment from mmc ...; " \
+ "env import -t $loadaddr $filesize\0" \
+ "bootenv=uEnv.txt\0" \
+ "loadbootenv=fatload mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \
"importbootenv=echo Importing environment from mmc ...; " \
"env import -t $loadaddr $filesize\0" \
"loaduimage=fatload mmc ${mmcdev} ${loadaddr} uImage\0" \
@@ -182,6 +187,18 @@
"pxe boot;" \
"fi"
#else
+#define CONFIG_PREBOOT \
+ "echo checking for ${preenv};" \
+ "if mmc rescan ${mmcdev}; then " \
+ "if run loadpreenv; then " \
+ "echo Loaded environment from ${preenv};" \
+ "run importpreenv;" \
+ "if test -n $preenvcmd; then " \
+ "echo Running preenvcmd ...;" \
+ "run preenvcmd;" \
+ "fi;" \
+ "fi; " \
+ "fi"
#define CONFIG_BOOTCOMMAND \
"if mmc rescan ${mmcdev}; then " \
"if run loadbootenv; then " \