From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerlando Falauto Date: Tue, 08 Nov 2011 13:04:13 +0100 Subject: [U-Boot] [PATCH v0 0/4] env: reworking + default/import individual vars In-Reply-To: <20111108114634.8248B13BE0C1@gemini.denx.de> References: <1319647072-17504-1-git-send-email-gerlando.falauto@keymile.com> <20111106221508.E4BFB1893017@gemini.denx.de> <4EB8F762.1030508@keymile.com> <20111108114634.8248B13BE0C1@gemini.denx.de> Message-ID: <4EB91ABD.90206@keymile.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 11/08/2011 12:46 PM, Wolfgang Denk wrote: > Dear Gerlando Falauto, > > In message<4EB8F762.1030508@keymile.com> you wrote: >> >> I tested "env import" with and without -n. Same for "env default". >> Also tested special variables. >> >> > For me, env import is broken now. >> >> I am not able to see how it's obviously broken. > > It just didn't work for me. Honestly, I didn't try it against the latest master branch. >> Perhaps you mean that when you don't provide an argument to -n, the >> following argument (e.g., -t) is interpreted as a variable name (and >> therefore consumed)? That doesn't look like an error to me. > > Yes, this is a serious bug. Aor design problem. > > The whole interface is wrong. I have just extendend "env export" to > do a similar thing. The new syntax is: > > env export [-t | -b | -c] [-s size] addr [var ...] When/where? I can't see that in the latest master branch. > We should do exactly the same for "env > import", i. e. make the size parameter an option to be passed with > "-s size", and pass the names of any variables to import as additional > arguments: > > env import [-t | -b | -c] [-s size] addr [var ...] > > This also greatly simplifies the implementation. Totally agree. Question is: won't that break all the existing scripts??? If you agree, I can post an updated patch with the same behavior for import. Although I am bit concerned about our scripts. Best, Gerlando Falauto