summaryrefslogtreecommitdiffstats
path: root/common/cmd_nvedit.c
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2008-02-23 12:15:56 +0100
committerWolfgang Denk <wd@denx.de>2008-02-23 20:37:59 +0100
commit00b48a48424894daa589d166d73277830b1c6ac4 (patch)
tree7b69fb1b329d1dcb0fe2457f4c408ce507e19899 /common/cmd_nvedit.c
parentb075d74efb70ff68c49a2532f26b56d6703b69c1 (diff)
downloadbootable_bootloader_goldelico_gta04-00b48a48424894daa589d166d73277830b1c6ac4.tar.gz
bootable_bootloader_goldelico_gta04-00b48a48424894daa589d166d73277830b1c6ac4.tar.bz2
bootable_bootloader_goldelico_gta04-00b48a48424894daa589d166d73277830b1c6ac4.zip
ENV: remove saveenv when CFG_ENV_IS_NOWHERE is selected
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Diffstat (limited to 'common/cmd_nvedit.c')
-rw-r--r--common/cmd_nvedit.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/common/cmd_nvedit.c b/common/cmd_nvedit.c
index dd263b666..cab727f76 100644
--- a/common/cmd_nvedit.c
+++ b/common/cmd_nvedit.c
@@ -550,10 +550,11 @@ int getenv_r (char *name, char *buf, unsigned len)
return (-1);
}
-#if defined(CFG_ENV_IS_IN_NVRAM) || defined(CFG_ENV_IS_IN_EEPROM) \
+#if ((defined(CFG_ENV_IS_IN_NVRAM) || defined(CFG_ENV_IS_IN_EEPROM) \
|| (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_FLASH)) \
|| (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_NAND)) \
- || (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_ONENAND))
+ || (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_ONENAND))) \
+ && !defined(CFG_ENV_IS_NOWHERE))
int do_saveenv (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
{
extern char * env_name_spec;
@@ -605,10 +606,11 @@ U_BOOT_CMD(
" - delete environment variable 'name'\n"
);
-#if defined(CFG_ENV_IS_IN_NVRAM) || defined(CFG_ENV_IS_IN_EEPROM) \
+#if ((defined(CFG_ENV_IS_IN_NVRAM) || defined(CFG_ENV_IS_IN_EEPROM) \
|| (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_FLASH)) \
|| (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_NAND)) \
- || (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_ONENAND))
+ || (defined(CONFIG_CMD_ENV) && defined(CONFIG_CMD_ONENAND))) \
+ && !defined(CFG_ENV_IS_NOWHERE))
U_BOOT_CMD(
saveenv, 1, 0, do_saveenv,
"saveenv - save environment variables to persistent storage\n",