summaryrefslogtreecommitdiff
path: root/env/mmc.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2017-08-03 12:22:04 -0600
committerTom Rini <trini@konsulko.com>2017-08-15 20:50:28 -0400
commit98b5755fb0484ac575b66784865bde2b30ea1d87 (patch)
treea193900623bfc951c11239daf3409be84622a79c /env/mmc.c
parentac358beb85362fb2fac47aaec40a7e1bca49656c (diff)
env: Drop unused env_ptr variables
This variable is declared as a global in most environment location drivers. But it is not used outside the drivers and most of the declarations are unnecessary. Also some drivers call free() on env_ptr which seems wrong since it is not in the heap. Drop the variable where possible, and all calls to free(). Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'env/mmc.c')
-rw-r--r--env/mmc.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/env/mmc.c b/env/mmc.c
index 18da6dc58c..88ffc91f0b 100644
--- a/env/mmc.c
+++ b/env/mmc.c
@@ -23,12 +23,6 @@
#error CONFIG_ENV_SIZE_REDUND should be the same as CONFIG_ENV_SIZE
#endif
-#ifdef ENV_IS_EMBEDDED
-env_t *env_ptr = &environment;
-#else /* ! ENV_IS_EMBEDDED */
-env_t *env_ptr;
-#endif /* ENV_IS_EMBEDDED */
-
DECLARE_GLOBAL_DATA_PTR;
#if !defined(CONFIG_ENV_OFFSET)