aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2019-08-01 09:46:44 -0600
committerTom Rini <trini@konsulko.com>2019-08-11 16:43:41 -0400
commit3f989e7b0e43402d0a50e19939e4f57374319734 (patch)
tree7e225bdfdeed2562cf00c8c9a5ee9e3757b41261
parent4bfd1f5d626778dd17f9827e5c462cc2697e0e90 (diff)
downloadu-boot-3f989e7b0e43402d0a50e19939e4f57374319734.zip
u-boot-3f989e7b0e43402d0a50e19939e4f57374319734.tar.gz
u-boot-3f989e7b0e43402d0a50e19939e4f57374319734.tar.bz2
env: Move env_relocate() to env.h
Move env_relocate() over to the new header file. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
-rw-r--r--common/board_r.c1
-rw-r--r--env/common.c1
-rw-r--r--include/common.h1
-rw-r--r--include/env.h8
4 files changed, 10 insertions, 1 deletions
diff --git a/common/board_r.c b/common/board_r.c
index 84aec7f..99b1285 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -18,6 +18,7 @@
#include <command.h>
#include <console.h>
#include <dm.h>
+#include <env.h>
#include <environment.h>
#include <fdtdec.h>
#include <ide.h>
diff --git a/env/common.c b/env/common.c
index bd340fe..1fbc4a8 100644
--- a/env/common.c
+++ b/env/common.c
@@ -9,6 +9,7 @@
#include <common.h>
#include <command.h>
+#include <env.h>
#include <environment.h>
#include <linux/stddef.h>
#include <search.h>
diff --git a/include/common.h b/include/common.h
index 55cbe1f..cb6b584 100644
--- a/include/common.h
+++ b/include/common.h
@@ -146,7 +146,6 @@ int do_fat_fsload(cmd_tbl_t *, int, int, char * const []);
int do_ext2load(cmd_tbl_t *, int, int, char * const []);
/* common/cmd_nvedit.c */
-void env_relocate (void);
int envmatch (uchar *, int);
/**
diff --git a/include/env.h b/include/env.h
index 5d205ef..7298096 100644
--- a/include/env.h
+++ b/include/env.h
@@ -32,6 +32,14 @@ int env_get_id(void);
int env_init(void);
/**
+ * env_relocate() - Set up the post-relocation environment
+ *
+ * This loads the environment into RAM so that it can be modified. This is
+ * called after relocation, before the environment is used
+ */
+void env_relocate(void);
+
+/**
* env_get_f() - Look up the value of an environment variable (early)
*
* This function is called from env_get() if the environment has not been