
Dear Gerlando Falauto,
In message 1319647072-17504-1-git-send-email-gerlando.falauto@keymile.com you wrote:
This is a resubmission (after removing remove checkpatch errors) of http://lists.denx.de/pipermail/u-boot/2011-September/102875.html
Here I am proposing a set of changes in the behaviour of the environment import/set_to_default functions.
PATCH 1: Add a "new" himport_ex() function (reworking of himport_r which is now a wrapper around it), which has 3 new arguments:
"nvars", "vars":, number and list of variables to take into account (0 means ALL)
"apply" callback function which is in charge of checking whether a variable can be overwritten, and possibly immediately apply the changes. This parameter would be either set to NULL (in which case nothing should change wrt to the past -- i.e. environment is blindly imported) or to "env_check_apply()" function, whose code was taken away from _do_env_set(). This would be useful, for instance, for "baudrate" or "stdin,stderr,stdout", whose changes would not otherwise be effective until the next reboot.
The idea is that there should be a single place where all the checks are to be performed. So the same function env_check_apply() is called from _do_env_set() as well (thus keeping the previous behavior).
Would you please also update the help messages for the respective commands so we can see their correct (new) usage there?
Thanks.
Wolfgang Denk