env: Move env_get_ulong() to env.h
authorSimon Glass <sjg@chromium.org>
Thu, 1 Aug 2019 15:46:48 +0000 (09:46 -0600)
committerTom Rini <trini@konsulko.com>
Sun, 11 Aug 2019 20:43:41 +0000 (16:43 -0400)
Move env_get_ulong() over to the new header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
board/BuR/brxre1/board.c
board/gdsys/p1022/controlcenterd-id.c
board/synopsys/hsdk/env-lib.c
board/ti/ks2_evm/board_k2g.c
board/toradex/colibri_imx6/colibri_imx6.c
include/common.h
include/env.h
lib/fdtdec.c
net/bootp.c

index 0d1c6c4..873208c 100644 (file)
@@ -9,6 +9,7 @@
  *
  */
 #include <common.h>
+#include <env.h>
 #include <errno.h>
 #include <spl.h>
 #include <asm/arch/cpu.h>
index 6ac956c..43f5404 100644 (file)
@@ -12,6 +12,7 @@
 
 #include <common.h>
 #include <dm.h>
+#include <env.h>
 #include <malloc.h>
 #include <fs.h>
 #include <i2c.h>
index 66e4581..f443c21 100644 (file)
@@ -5,6 +5,7 @@
  */
 
 #include "env-lib.h"
+#include <env.h>
 
 #define MAX_CMD_LEN    25
 
index 6d0fc21..4ff9a44 100644 (file)
@@ -6,6 +6,7 @@
  *     Texas Instruments Incorporated, <www.ti.com>
  */
 #include <common.h>
+#include <env.h>
 #include <asm/arch/clock.h>
 #include <asm/ti-common/keystone_net.h>
 #include <asm/arch/psc_defs.h>
index 6417ba4..f657db8 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <common.h>
 #include <dm.h>
+#include <env.h>
 
 #include <asm/arch/clock.h>
 #include <asm/arch/crm_regs.h>
index 283cb23..48f443e 100644 (file)
@@ -157,19 +157,6 @@ int do_ext2load(cmd_tbl_t *, int, int, char * const []);
  */
 char *env_get(const char *varname);
 
-/**
- * env_get_ulong() - Return an environment variable as an integer value
- *
- * Most U-Boot environment variables store hex values. For those which store
- * (e.g.) base-10 integers, this function can be used to read the value.
- *
- * @name:      Variable to look up
- * @base:      Base to use (e.g. 10 for base 10, 2 for binary)
- * @default_val: Default value to return if no value is found
- * @return the value found, or @default_val if none
- */
-ulong env_get_ulong(const char *name, int base, ulong default_val);
-
 /**
  * env_get_hex() - Return an environment variable as a hex value
  *
index 8898b78..9124718 100644 (file)
@@ -63,6 +63,19 @@ int env_match(unsigned char *name, int index);
  */
 int env_get_f(const char *name, char *buf, unsigned int len);
 
+/**
+ * env_get_ulong() - Return an environment variable as an integer value
+ *
+ * Most U-Boot environment variables store hex values. For those which store
+ * (e.g.) base-10 integers, this function can be used to read the value.
+ *
+ * @name:      Variable to look up
+ * @base:      Base to use (e.g. 10 for base 10, 2 for binary)
+ * @default_val: Default value to return if no value is found
+ * @return the value found, or @default_val if none
+ */
+ulong env_get_ulong(const char *name, int base, ulong default_val);
+
 /**
  * env_set_ulong() - set an environment variable to an integer
  *
index 464de5b..ef5e548 100644 (file)
@@ -8,6 +8,7 @@
 #include <boot_fit.h>
 #include <dm.h>
 #include <dm/of_extra.h>
+#include <env.h>
 #include <errno.h>
 #include <fdtdec.h>
 #include <fdt_support.h>
index 9a2b512..5054891 100644 (file)
@@ -10,6 +10,7 @@
 
 #include <common.h>
 #include <command.h>
+#include <env.h>
 #include <efi_loader.h>
 #include <net.h>
 #include <net/tftp.h>