<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/common/cmd_nvedit.c, branch v2011.06</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>cmd_nvedit.c: make error message more helpful</title>
<updated>2011-05-12T17:47:14+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2011-05-04T10:29:49+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=a02a884b95c47e114a54f2751d03f139f312af2f'/>
<id>a02a884b95c47e114a54f2751d03f139f312af2f</id>
<content type='text'>
When calling getenv_f() with a too small buffer, it would print an
error message like this:

	env_buf too small [32]

This is not really helpful as it does not give any indication which of
the calls might have failed.  Change this into:

	env_buf [32 bytes] too small for value of "hwconfig"

so we know at least which variable caused the overflow; this usually
allows to quickly find the related code as well.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When calling getenv_f() with a too small buffer, it would print an
error message like this:

	env_buf too small [32]

This is not really helpful as it does not give any indication which of
the calls might have failed.  Change this into:

	env_buf [32 bytes] too small for value of "hwconfig"

so we know at least which variable caused the overflow; this usually
allows to quickly find the related code as well.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cmd_nvedit.c: clean up with checkpatch</title>
<updated>2011-04-30T20:27:19+00:00</updated>
<author>
<name>Macpaul Lin</name>
<email>macpaul@andestech.com</email>
</author>
<published>2011-04-26T16:16:45+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=f3c615b8abc098f5222b061b81c75f1363ff4d32'/>
<id>f3c615b8abc098f5222b061b81c75f1363ff4d32</id>
<content type='text'>
Code clean up of cmd_nvedit.c by using checkpatch.pl.

Signed-off-by: Macpaul Lin &lt;macpaul@andestech.com&gt;
Acked-by: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Code clean up of cmd_nvedit.c by using checkpatch.pl.

Signed-off-by: Macpaul Lin &lt;macpaul@andestech.com&gt;
Acked-by: Detlev Zundel &lt;dzu@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>common: add a grepenv command</title>
<updated>2011-04-27T23:00:07+00:00</updated>
<author>
<name>Kim Phillips</name>
<email>kim.phillips@freescale.com</email>
</author>
<published>2011-04-05T07:15:14+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=a000b7950da938d2df37ec5e081cd0680e6e4bbe'/>
<id>a000b7950da938d2df37ec5e081cd0680e6e4bbe</id>
<content type='text'>
u-boot environments, esp. when boards are shared across multiple
users, can get pretty large and time consuming to visually parse.
The grepenv command this patch adds can be used in lieu of printenv
to facilitate searching.  grepenv works like printenv but limits
its output only to environment strings (variable name and value
pairs) that match the user specified substring.

the following examples are on a board with a 5313 byte environment
that spans multiple screen pages:

Example 1:  summarize ethernet configuration:

=&gt; grepenv eth TSEC
etact=FM1@DTSEC2
eth=FM1@DTSEC4
ethact=FM1@DTSEC2
eth1addr=00:E0:0C:00:8b:01
eth2addr=00:E0:0C:00:8b:02
eth3addr=00:E0:0C:00:8b:03
eth4addr=00:E0:0C:00:8b:04
eth5addr=00:E0:0C:00:8b:05
eth6addr=00:E0:0C:00:8b:06
eth7addr=00:E0:0C:00:8b:07
eth8addr=00:E0:0C:00:8b:08
eth9addr=00:E0:0C:00:8b:09
ethaddr=00:E0:0C:00:8b:00
netdev=eth0
uprcw=setenv ethact $eth;setenv filename p4080ds/R_PPSXX_0xe/rcw_0xe_2sgmii_rev2_high.bin;setenv start 0xe8000000;protect off all;run upimage;protect on all
upuboot=setenv ethact $eth;setenv filename u-boot.bin;setenv start eff80000;protect off all;run upimage;protect on all
upucode=setenv ethact $eth;setenv filename fsl_fman_ucode_P4080_101_6.bin;setenv start 0xef000000;protect off all;run upimage;protect on all
usdboot=setenv ethact $eth;tftp 1000000 $dir/$bootfile;tftp 2000000 $dir/initramfs.cpio.gz.uboot;tftp c00000 $dir/p4080ds-usdpaa.dtb;setenv bootargs root=/dev/ram rw console=ttyS0,115200 $othbootargs;bootm 1000000 2000000 c00000;
=&gt;

Example 2: detect unused env vars:

=&gt; grepenv etact
etact=FM1@DTSEC2
=&gt;

Example 3: reveal hardcoded variables; e.g., for fdtaddr:

=&gt; grepenv fdtaddr
fdtaddr=c00000
nfsboot=setenv bootargs root=/dev/nfs rw nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off console=$consoledev,$baudrate $othbootargs;tftp $loadaddr $bootfile;tftp $fdtaddr $fdtfile;bootm $loadaddr - $fdtaddr
ramboot=setenv bootargs root=/dev/ram rw console=$consoledev,$baudrate $othbootargs;tftp $ramdiskaddr $ramdiskfile;tftp $loadaddr $bootfile;tftp $fdtaddr $fdtfile;bootm $loadaddr $ramdiskaddr $fdtaddr
=&gt; grep $fdtaddr
fdtaddr=c00000
my_boot=bootm 0x40000000 0x41000000 0x00c00000
my_dtb=tftp 0x00c00000 $prefix/p4080ds.dtb
nohvboot=tftp 1000000 $dir/$bootfile;tftp 2000000 $dir/$ramdiskfile;tftp c00000 $dir/$fdtfile;setenv bootargs root=/dev/ram rw ramdisk_size=0x10000000 console=ttyS0,115200;bootm 1000000 2000000 c00000;
=&gt;

This patch also enables the grepenv command by default on
corenet_ds based boards (and repositions the DHCP command
entry to keep the list sorted).

Signed-off-by: Kim Phillips &lt;kim.phillips@freescale.com&gt;
Cc: Kumar Gala &lt;kumar.gala@freescale.com&gt;
Cc: Andy Fleming &lt;afleming@freescale.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
u-boot environments, esp. when boards are shared across multiple
users, can get pretty large and time consuming to visually parse.
The grepenv command this patch adds can be used in lieu of printenv
to facilitate searching.  grepenv works like printenv but limits
its output only to environment strings (variable name and value
pairs) that match the user specified substring.

the following examples are on a board with a 5313 byte environment
that spans multiple screen pages:

Example 1:  summarize ethernet configuration:

=&gt; grepenv eth TSEC
etact=FM1@DTSEC2
eth=FM1@DTSEC4
ethact=FM1@DTSEC2
eth1addr=00:E0:0C:00:8b:01
eth2addr=00:E0:0C:00:8b:02
eth3addr=00:E0:0C:00:8b:03
eth4addr=00:E0:0C:00:8b:04
eth5addr=00:E0:0C:00:8b:05
eth6addr=00:E0:0C:00:8b:06
eth7addr=00:E0:0C:00:8b:07
eth8addr=00:E0:0C:00:8b:08
eth9addr=00:E0:0C:00:8b:09
ethaddr=00:E0:0C:00:8b:00
netdev=eth0
uprcw=setenv ethact $eth;setenv filename p4080ds/R_PPSXX_0xe/rcw_0xe_2sgmii_rev2_high.bin;setenv start 0xe8000000;protect off all;run upimage;protect on all
upuboot=setenv ethact $eth;setenv filename u-boot.bin;setenv start eff80000;protect off all;run upimage;protect on all
upucode=setenv ethact $eth;setenv filename fsl_fman_ucode_P4080_101_6.bin;setenv start 0xef000000;protect off all;run upimage;protect on all
usdboot=setenv ethact $eth;tftp 1000000 $dir/$bootfile;tftp 2000000 $dir/initramfs.cpio.gz.uboot;tftp c00000 $dir/p4080ds-usdpaa.dtb;setenv bootargs root=/dev/ram rw console=ttyS0,115200 $othbootargs;bootm 1000000 2000000 c00000;
=&gt;

Example 2: detect unused env vars:

=&gt; grepenv etact
etact=FM1@DTSEC2
=&gt;

Example 3: reveal hardcoded variables; e.g., for fdtaddr:

=&gt; grepenv fdtaddr
fdtaddr=c00000
nfsboot=setenv bootargs root=/dev/nfs rw nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off console=$consoledev,$baudrate $othbootargs;tftp $loadaddr $bootfile;tftp $fdtaddr $fdtfile;bootm $loadaddr - $fdtaddr
ramboot=setenv bootargs root=/dev/ram rw console=$consoledev,$baudrate $othbootargs;tftp $ramdiskaddr $ramdiskfile;tftp $loadaddr $bootfile;tftp $fdtaddr $fdtfile;bootm $loadaddr $ramdiskaddr $fdtaddr
=&gt; grep $fdtaddr
fdtaddr=c00000
my_boot=bootm 0x40000000 0x41000000 0x00c00000
my_dtb=tftp 0x00c00000 $prefix/p4080ds.dtb
nohvboot=tftp 1000000 $dir/$bootfile;tftp 2000000 $dir/$ramdiskfile;tftp c00000 $dir/$fdtfile;setenv bootargs root=/dev/ram rw ramdisk_size=0x10000000 console=ttyS0,115200;bootm 1000000 2000000 c00000;
=&gt;

This patch also enables the grepenv command by default on
corenet_ds based boards (and repositions the DHCP command
entry to keep the list sorted).

Signed-off-by: Kim Phillips &lt;kim.phillips@freescale.com&gt;
Cc: Kumar Gala &lt;kumar.gala@freescale.com&gt;
Cc: Andy Fleming &lt;afleming@freescale.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix typo in #error: IS_IN_NOWHERE vs. IS_NOWHERE</title>
<updated>2011-04-25T22:04:02+00:00</updated>
<author>
<name>LoÃ¯c Minier</name>
<email>loic.minier@linaro.org</email>
</author>
<published>2011-03-24T16:21:42+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=31e413985c58ea1e802c82e39b5f2650ecc0695e'/>
<id>31e413985c58ea1e802c82e39b5f2650ecc0695e</id>
<content type='text'>
Signed-off-by: Loïc Minier &lt;loic.minier@linaro.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Loïc Minier &lt;loic.minier@linaro.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>env: make import/export optional</title>
<updated>2011-04-13T19:56:34+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2010-12-27T04:09:45+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=0c79cda01b75e2f263ec4a5dd81f693b37392ea9'/>
<id>0c79cda01b75e2f263ec4a5dd81f693b37392ea9</id>
<content type='text'>
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cmd_nvedit: use explicit typecast for printf</title>
<updated>2011-04-12T20:58:32+00:00</updated>
<author>
<name>Andreas BieÃŸmann</name>
<email>biessmann@corscience.de</email>
</author>
<published>2011-02-09T14:10:29+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8c3aff525c710a8a53c96e0bb98c988483429418'/>
<id>8c3aff525c710a8a53c96e0bb98c988483429418</id>
<content type='text'>
This patch fixes warnings in MAKEALL for avr32:

---8&lt;---
cmd_nvedit.c: In function 'do_env_export':
cmd_nvedit.c:663: warning: format '%zX' expects type 'size_t', but argument 3 has type 'ssize_t'
---&gt;8---

Signed-off-by: Andreas Bießmann &lt;biessmann@corscience.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch fixes warnings in MAKEALL for avr32:

---8&lt;---
cmd_nvedit.c: In function 'do_env_export':
cmd_nvedit.c:663: warning: format '%zX' expects type 'size_t', but argument 3 has type 'ssize_t'
---&gt;8---

Signed-off-by: Andreas Bießmann &lt;biessmann@corscience.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>load_addr: move to common env code</title>
<updated>2011-01-09T17:02:06+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2010-12-21T19:08:27+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=558605cf4fe9558dff9b8ea2241fbeb526dc353d'/>
<id>558605cf4fe9558dff9b8ea2241fbeb526dc353d</id>
<content type='text'>
Rather than keep the load_addr definition with the bootm code (which
just happens to use this), move it to the common env code.  This way
we can disable bootm support completely while retaining load_addr
usage with many other commands.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rather than keep the load_addr definition with the bootm code (which
just happens to use this), move it to the common env code.  This way
we can disable bootm support completely while retaining load_addr
usage with many other commands.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hashtable: drop all non-reentrant versions</title>
<updated>2010-12-17T20:07:14+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2010-12-08T11:26:04+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=2eb1573f01710832bbe60a4ece89cb301727612a'/>
<id>2eb1573f01710832bbe60a4ece89cb301727612a</id>
<content type='text'>
The non-reentrant versions of the hashtable functions operate on a single
shared hashtable.  So if two different people try using these funcs for
two different purposes, they'll cause problems for the other.

Avoid this by converting all existing hashtable consumers over to the
reentrant versions and then punting the non-reentrant ones.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The non-reentrant versions of the hashtable functions operate on a single
shared hashtable.  So if two different people try using these funcs for
two different purposes, they'll cause problems for the other.

Avoid this by converting all existing hashtable consumers over to the
reentrant versions and then punting the non-reentrant ones.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>autocomplete: remove runtime handler install</title>
<updated>2010-11-28T20:49:27+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2010-10-20T07:52:39+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=722b061b6f6f3405118f2969272511e7e19990e3'/>
<id>722b061b6f6f3405118f2969272511e7e19990e3</id>
<content type='text'>
Rather than add runtime overhead of installing completion handlers, do it
statically at build time.  This requires a new build time helper macro to
declare a command and the completion handler at the same time.  Then we
convert the env related funcs over to this.

This gives an opportunity to also unify the U_BOOT_CMD macros.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rather than add runtime overhead of installing completion handlers, do it
statically at build time.  This requires a new build time helper macro to
declare a command and the completion handler at the same time.  Then we
convert the env related funcs over to this.

This gives an opportunity to also unify the U_BOOT_CMD macros.

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>common/cmd_nvedit: Use return value of cmd_usage</title>
<updated>2010-11-27T22:35:13+00:00</updated>
<author>
<name>Thomas Weber</name>
<email>weber@corscience.de</email>
</author>
<published>2010-11-25T07:05:28+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=0d302af0bb7e0be40d960bd2d8ee0a91dc9e2bbf'/>
<id>0d302af0bb7e0be40d960bd2d8ee0a91dc9e2bbf</id>
<content type='text'>
Use the return value of cmd_usage instead of ignoring this
and returning a 1.

Signed-off-by: Thomas Weber &lt;weber@corscience.de&gt;
Acked-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use the return value of cmd_usage instead of ignoring this
and returning a 1.

Signed-off-by: Thomas Weber &lt;weber@corscience.de&gt;
Acked-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
