From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wolfgang Denk Date: Wed, 22 Jun 2011 19:32:12 +0200 Subject: [U-Boot] tftp "command" in default environments In-Reply-To: <4E01FC2B.3010402@comelit.it> References: <4E01FC2B.3010402@comelit.it> Message-ID: <20110622173212.7A57713D91CD@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear "Luca Ceresoli", In message <4E01FC2B.3010402@comelit.it> you wrote: > > since 7a83af07aef3c (TFTP: add tftpsrv command) U-Boot has a new "tftpsrv" > command, which can be enabled by defining CONFIG_CMD_TFTPSRV. Right. > Unfortunately, activating it causes some boards to stop working correctly. I think this is not quite correct. I don't see any broken board. > This is because they use the tftp "command" in their environment, but tftp is > has never been a real command, just the prefix for tftpboot. > tftpboot used to be the sole completion for the tftp prefix, and this is still > true unless one activates tftpsrv. Correct. So only those board maintainers that use "tftp" as abbreviation _and_ now changing their board configuration to include the "tftpsrv" need to pay attention. > This is of course a bug in many boards (and the docs too). It is not a bug. It is a pretty normal situation that people use abbreviations as long as they work. When working interactively, I used to use "set" for a long, long time instead of "setenv", until it stopped working. Then I used to use "sete" (and still do this) except for boards that enable for example the "setexpr" command. We just should try not to use such abbreviations in the environment, and/or pay special attention to check the environment when changing the board configuration to include new, additional commands. > It's obviously to be fixed for boards that define CONFIG_CMD_TFTPSRV: > currently none, but soon I'll update dig297 in this sense. Then make sure to check the default env. > What I'm not sure about is if the default environment for all boards should be > fixed as well. No. Most of them will never enable the "tftpsrv" command. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de In C we had to code our own bugs, in C++ we can inherit them.