[U-Boot] [PATCH V2] Tools: set multiple variable with fw_setenv utility

Peter Tyser ptyser at xes-inc.com
Mon May 24 04:47:19 CEST 2010


Hi Stefano,

On Sun, 2010-05-23 at 16:29 +0200, Stefano Babic wrote:
> Add a sort of batch mode to fw_setenv, allowing to set
> multiple variables in one shot, without updating the flash after
> each set as now. It is added the possibility to pass
> a config file with a list of pairs <variable, value> to be set,
> separated by a TAB character.

It'd be nice to document the new functionality you're adding.  Any
interest in adding a runtime usage message?  It seems like that'd be
pretty useful.  At a minimum it would be nice to update the description
in fw_env_main.c to reflect the changes you're making and/or update the
README.

> -int fw_setenv (int argc, char *argv[])
> +int fw_env_open(void)
>  {
> -	int i, len;
> -	char *env, *nxt;
> -	char *oldval = NULL;
> -	char *name;
> +	return env_init();
> +}

Is there a reason to keep fw_env_open around?  It looks like just a call
to env_init() after the changes above?

Best,
Peter



More information about the U-Boot mailing list