diff options
author | Simon Glass <sjg@chromium.org> | 2017-08-03 12:22:09 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2017-08-16 08:22:18 -0400 |
commit | 382bee57f19b4454e2015bc19a010bc2d0ab9337 (patch) | |
tree | 8c13efda2a6539cdbf1ac76fc458ffef1e9c966d /board/siemens/taurus | |
parent | 01510091de905c46620757b9027b2e55c4b3b313 (diff) |
env: Rename setenv() to env_set()
We are now using an env_ prefix for environment functions. Rename setenv()
for consistency. Also add function comments in common.h.
Suggested-by: Wolfgang Denk <wd@denx.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'board/siemens/taurus')
-rw-r--r-- | board/siemens/taurus/taurus.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/board/siemens/taurus/taurus.c b/board/siemens/taurus/taurus.c index 3b742ebc22..d877a9c771 100644 --- a/board/siemens/taurus/taurus.c +++ b/board/siemens/taurus/taurus.c @@ -380,9 +380,9 @@ static int upgrade_failure_fallback(void) partitionset_active = getenv("partitionset_active"); if (partitionset_active) { if (partitionset_active[0] == 'A') - setenv("partitionset_active", "B"); + env_set("partitionset_active", "B"); else - setenv("partitionset_active", "A"); + env_set("partitionset_active", "A"); } else { printf("partitionset_active missing.\n"); return -ENOENT; @@ -390,22 +390,22 @@ static int upgrade_failure_fallback(void) rootfs = getenv("rootfs"); rootfs_fallback = getenv("rootfs_fallback"); - setenv("rootfs", rootfs_fallback); - setenv("rootfs_fallback", rootfs); + env_set("rootfs", rootfs_fallback); + env_set("rootfs_fallback", rootfs); kern_size = getenv("kernel_size"); kern_size_fb = getenv("kernel_size_fallback"); - setenv("kernel_size", kern_size_fb); - setenv("kernel_size_fallback", kern_size); + env_set("kernel_size", kern_size_fb); + env_set("kernel_size_fallback", kern_size); kern_off = getenv("kernel_Off"); kern_off_fb = getenv("kernel_Off_fallback"); - setenv("kernel_Off", kern_off_fb); - setenv("kernel_Off_fallback", kern_off); + env_set("kernel_Off", kern_off_fb); + env_set("kernel_Off_fallback", kern_off); - setenv("bootargs", '\0'); - setenv("upgrade_available", '\0'); - setenv("boot_retries", '\0'); + env_set("bootargs", '\0'); + env_set("upgrade_available", '\0'); + env_set("boot_retries", '\0'); env_save(); return 0; @@ -424,7 +424,7 @@ static int do_upgrade_available(cmd_tbl_t *cmdtp, int flag, int argc, boot_retry = simple_strtoul(getenv("boot_retries"), NULL, 10); boot_retry++; sprintf(boot_buf, "%lx", boot_retry); - setenv("boot_retries", boot_buf); + env_set("boot_retries", boot_buf); env_save(); /* |