From 7938822a6b75b69fff9793b6b1769dddf1249525 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Thu, 3 Aug 2017 12:22:02 -0600 Subject: env: Drop common init() functions Most of the init() implementations just use the default environment. Adjust env_init_new() to do this automatically, and drop the redundant code. Signed-off-by: Simon Glass Reviewed-by: Tom Rini --- env/eeprom.c | 14 -------------- 1 file changed, 14 deletions(-) (limited to 'env/eeprom.c') diff --git a/env/eeprom.c b/env/eeprom.c index eb69f75..3cc4126 100644 --- a/env/eeprom.c +++ b/env/eeprom.c @@ -231,23 +231,9 @@ static int env_eeprom_save(void) return rc; } -/* - * Initialize Environment use - * - * We are still running from ROM, so data use is limited. - * Use a (moderately small) buffer on the stack - */ -static int env_eeprom_init(void) -{ - gd->env_addr = (ulong)&default_environment[0]; - gd->env_valid = ENV_VALID; - return 0; -} - U_BOOT_ENV_LOCATION(eeprom) = { .location = ENVL_EEPROM, .get_char = env_eeprom_get_char, .load = env_eeprom_load, .save = env_save_ptr(env_eeprom_save), - .init = env_eeprom_init, }; -- cgit v1.1