diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/common.h | 6 | ||||
| -rw-r--r-- | include/env.h | 8 |
2 files changed, 8 insertions, 6 deletions
diff --git a/include/common.h b/include/common.h index 48f443e851c..83050073bf2 100644 --- a/include/common.h +++ b/include/common.h @@ -169,12 +169,6 @@ char *env_get(const char *varname); */ ulong env_get_hex(const char *varname, ulong default_val); -/* - * Read an environment variable as a boolean - * Return -1 if variable does not exist (default to true) - */ -int env_get_yesno(const char *var); - /** * env_set() - set an environment variable * diff --git a/include/env.h b/include/env.h index 9124718f2d6..d7190da335e 100644 --- a/include/env.h +++ b/include/env.h @@ -64,6 +64,14 @@ int env_match(unsigned char *name, int index); int env_get_f(const char *name, char *buf, unsigned int len); /** + * env_get_yesno() - Read an environment variable as a boolean + * + * @return 1 if yes/true (Y/y/T/t), -1 if variable does not exist (i.e. default + * to true), 0 if otherwise + */ +int env_get_yesno(const char *var); + +/** * env_get_ulong() - Return an environment variable as an integer value * * Most U-Boot environment variables store hex values. For those which store |
