env: Add an enum for environment state
[oweals/u-boot.git] / include / environment.h
index d86230a2e927e311b4e44d44c3f9dae481e778f8..ad2331c90b4d8f2e1f162b37ad1b6174b7c9a368 100644 (file)
@@ -197,15 +197,18 @@ extern uint mmc_get_env_part(struct mmc *mmc);
 #include <env_flags.h>
 #include <search.h>
 
+/* Value for environment validity */
+enum env_valid {
+       ENV_INVALID,    /* No valid environment */
+       ENV_VALID,      /* First or only environment is valid */
+       ENV_REDUND,     /* Redundant environment is valid */
+};
+
 extern struct hsearch_data env_htab;
 
 /* Function that returns a character from the environment */
 unsigned char env_get_char(int);
 
-/* Function that returns a pointer to a value from the environment */
-const unsigned char *env_get_addr(int);
-unsigned char env_get_char_memory(int index);
-
 /* Function that updates CRC of the enironment */
 void env_crc_update(void);