]> git.dujemihanovic.xyz Git - u-boot.git/commit
cmd: nvedit: propagate envflag to set_default_vars
authorYaniv Levinsky <yaniv.levinsky@compulab.co.il>
Sun, 24 Jun 2018 16:16:55 +0000 (19:16 +0300)
committerTom Rini <trini@konsulko.com>
Thu, 19 Jul 2018 20:17:58 +0000 (16:17 -0400)
commit477f8116d517798d4d6456d920d57ff2f46d4271
tree794f331d8570273b9b2582e79b79c2cd6642fa64
parent30091494eba7ddd788f0beaec04a986c3ba4f193
cmd: nvedit: propagate envflag to set_default_vars

The env_flag in do_env_default() doesn't get propagated and therefore
gets ignored by himport_r(). This breaks to ability to "forcibly" reset
variables to their default values using the environment command.

Scenario example of the problem:
# setenv kernel uImage
# setenv .flags kernel:so
# env default -f kernel
## Error: Can't overwrite "kernel"
himport_r: can't insert "kernel=zImage" into hash table

Change the call path so it will pass the flag correctly.

Signed-off-by: Yaniv Levinsky <yaniv.levinsky@compulab.co.il>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
cmd/nvedit.c
env/common.c
include/environment.h