<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/arch/powerpc/lib, branch v2010.09</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/u-boot.git/atom/arch/powerpc/lib?h=v2010.09</id>
<link rel='self' href='http://cgit.235523.xyz/u-boot.git/atom/arch/powerpc/lib?h=v2010.09'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<updated>2010-09-19T15:47:29Z</updated>
<entry>
<title>Save environment data to mmc.</title>
<updated>2010-09-19T15:47:29Z</updated>
<author>
<name>Terry Lv</name>
<email>r65388@freescale.com</email>
</author>
<published>2010-05-17T02:57:01Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=a80603598cef13ab8031b514a603ef1a6169d249'/>
<id>urn:sha1:a80603598cef13ab8031b514a603ef1a6169d249</id>
<content type='text'>
This patch is to save environment data to mmc card.
It uses interfaces defined in generic mmc.

Signed-off-by: Terry Lv &lt;r65388@freescale.com&gt;
Acked-by: Stefano Babic &lt;sbabic@denx.de&gt;
</content>
</entry>
<entry>
<title>fdt relocate: have more attention to use a bootmap or not</title>
<updated>2010-08-08T20:16:05Z</updated>
<author>
<name>Stephan Linz</name>
<email>linz@li-pro.net</email>
</author>
<published>2010-06-25T16:04:59Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=958e120643e8b6765b3ff84dfcf57624076afd21'/>
<id>urn:sha1:958e120643e8b6765b3ff84dfcf57624076afd21</id>
<content type='text'>
Platforms with flat device tree support can use a bootmap to relocate
the fdt_blob. This is not a must. That's why the relocation function
boot_relocate_fdt() should be use only if CONFIG_OF_LIBFDT was defined
together with CONFIG_SYS_BOOTMAPSZ (see common/cmd_bootm.c).

On MicroBlaze platforms there is no need to use a bootmap to relocate
a fdt blob. So we need a more precise focus on the compilation and usage
of boot_relocate_fdt().

In general it is valid to exclude the function boot_relocate_fdt() if
the bootmap size CONFIG_SYS_BOOTMAPSZ is not defined.

Signed-off-by: Stephan Linz &lt;linz@li-pro.net&gt;
</content>
</entry>
<entry>
<title>Rename getenv_r() into getenv_f()</title>
<updated>2010-08-03T22:45:36Z</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-07-24T19:55:43Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=cdb749778aa3a8f8d2a41dd4ad811ef822aecfe6'/>
<id>urn:sha1:cdb749778aa3a8f8d2a41dd4ad811ef822aecfe6</id>
<content type='text'>
While running from flash, i. e. before relocation, we have only a
limited C runtime environment without writable data segment. In this
phase, some configurations (for example with environment in EEPROM)
must not use the normal getenv(), but a special function.  This
function had been called getenv_r(), with the idea that the "_r"
suffix would mean the same as in the _r_eentrant versions of some of
the C library functions (for example getdate vs. getdate_r, getgrent
vs. getgrent_r, etc.).

Unfortunately this was a misleading name, as in U-Boot the "_r"
generally means "running from RAM", i. e. _after_ relocation.

To avoid confusion, rename into getenv_f() [as "running from flash"]

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
Acked-by: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
</entry>
<entry>
<title>Make sure that argv[] argument pointers are not modified.</title>
<updated>2010-07-04T21:55:42Z</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-06-28T20:00:46Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=54841ab50c20d6fa6c9cc3eb826989da3a22d934'/>
<id>urn:sha1:54841ab50c20d6fa6c9cc3eb826989da3a22d934</id>
<content type='text'>
The hush shell dynamically allocates (and re-allocates) memory for the
argument strings in the "char *argv[]" argument vector passed to
commands.  Any code that modifies these pointers will cause serious
corruption of the malloc data structures and crash U-Boot, so make
sure the compiler can check that no such modifications are being done
by changing the code into "char * const argv[]".

This modification is the result of debugging a strange crash caused
after adding a new command, which used the following argument
processing code which has been working perfectly fine in all Unix
systems since version 6 - but not so in U-Boot:

int main (int argc, char **argv)
{
	while (--argc &gt; 0 &amp;&amp; **++argv == '-') {
/* ====&gt; */	while (*++*argv) {
			switch (**argv) {
			case 'd':
				debug++;
				break;
			...
			default:
				usage ();
			}
		}
	}
	...
}

The line marked "====&gt;" will corrupt the malloc data structures and
usually cause U-Boot to crash when the next command gets executed by
the shell.  With the modification, the compiler will prevent this with
an
	error: increment of read-only location '*argv'

N.B.: The code above can be trivially rewritten like this:

	while (--argc &gt; 0 &amp;&amp; **++argv == '-') {
		char *arg = *argv;
		while (*++arg) {
			switch (*arg) {
			...

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
Acked-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
</entry>
<entry>
<title>Merge branch 'master' into next</title>
<updated>2010-06-29T23:02:11Z</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-06-29T23:02:11Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=0a9463e93537a68e7246714f43fb69eca0b7b214'/>
<id>urn:sha1:0a9463e93537a68e7246714f43fb69eca0b7b214</id>
<content type='text'>
</content>
</entry>
<entry>
<title>powerpc/bootcount: Add bootcount support for MPC512x</title>
<updated>2010-06-29T21:13:35Z</updated>
<author>
<name>Michael Weiss</name>
<email>michael.weiss@ifm.com</email>
</author>
<published>2010-05-20T14:09:34Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=955ea6fc2749a4305395758fc797cf8c11dcbed7'/>
<id>urn:sha1:955ea6fc2749a4305395758fc797cf8c11dcbed7</id>
<content type='text'>
This also uses the breadcrumb register as on MPC5200.

Signed-off-by: Michael Weiss &lt;michael.weiss@ifm.com&gt;
Signed-off-by: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
</entry>
<entry>
<title>MPC512x: workaround data corruption for unaligned local bus accesses</title>
<updated>2010-06-29T12:41:37Z</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-06-28T23:33:35Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=4ccd5510e50b5675227a1fe0e5ca099d333f637d'/>
<id>urn:sha1:4ccd5510e50b5675227a1fe0e5ca099d333f637d</id>
<content type='text'>
Commit 460c2ce3 "MPC5200: workaround data corruption for unaligned
local bus accesses" fixed the problem for MPC5200 only, but MPC512x is
affected as well, so apply the same fix here, too.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
Cc: Detlev Zundel &lt;dzu@denx.de&gt;
Cc: Anatolij Gustschin &lt;agust@denx.de&gt;
Acked-by: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
</entry>
<entry>
<title>MPC5200: workaround data corruption for unaligned local bus accesses</title>
<updated>2010-06-23T00:09:20Z</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-06-21T20:29:59Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=460c2ce362e56890c2a029e2c3b1ff2796c7fc54'/>
<id>urn:sha1:460c2ce362e56890c2a029e2c3b1ff2796c7fc54</id>
<content type='text'>
The MPC5200 has a nasty problem that will cause silent data corruption
when performing unaligned 16 or 32 byte accesses when reading from the
local bus - typically this affects reading from flash. The problem can
be easily shown:

=&gt; md fc0c0000 10
fc0c0000: 323e4337 01626f6f 74636d64 3d72756e    2&gt;C7.bootcmd=run
fc0c0010: 206e6574 5f6e6673 00626f6f 7464656c     net_nfs.bootdel
fc0c0020: 61793d35 00626175 64726174 653d3131    ay=5.baudrate=11
fc0c0030: 35323030 00707265 626f6f74 3d656368    5200.preboot=ech
=&gt; md fc0c0001 10
fc0c0001: 65636801 00000074 0000003d 00000020    ech....t...=...
fc0c0011: 0000005f 00000000 00000074 00000061    ..._.......t...a
fc0c0021: 00000000 00000064 00000065 00000035    .......d...e...5
fc0c0031: 00000000 00000062 0000003d 0000006f    .......b...=...o
=&gt; md.w fc0c0001 10
fc0c0001: 0000 3701 0000 6f74 0000 643d 0000 6e20    ..7...ot..d=..n
fc0c0011: 0000 745f 0000 7300 0000 6f74 0000 6c61    ..t_..s...ot..la

This commit implements a workaround at least for the most blatant
problem: using memcpy() from NOR flash. We rename the assembler
routine into __memcpy() and provide a wrapper, which will use a
byte-wise copy loop for unaligned source or target addresses when
reading from NOR flash, and branch to the optimized __memcpy()
in all other cases, thus minimizing the performance impact.

Tested on lite5200b and TQM5200S.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
Cc: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
</entry>
<entry>
<title>powerpc/bootcount: Fix endianness problem</title>
<updated>2010-05-26T20:26:32Z</updated>
<author>
<name>Michael Weiss</name>
<email>michael.weiss@ifm.com</email>
</author>
<published>2010-05-20T14:09:35Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=59dde44acb82e571808190ccd3cd6b82dc9d7001'/>
<id>urn:sha1:59dde44acb82e571808190ccd3cd6b82dc9d7001</id>
<content type='text'>
For CONFIG_SYS_BOOTCOUNT_SINGLEWORD the code had an endianness problem.

Signed-off-by: Michael Weiss &lt;michael.weiss@ifm.com&gt;
Signed-off-by: Detlev Zundel &lt;dzu@denx.de&gt;
</content>
</entry>
<entry>
<title>powerpc: Consolidate bootcount_{store|load} for PowerPC</title>
<updated>2010-05-06T21:28:48Z</updated>
<author>
<name>Stefan Roese</name>
<email>sr@denx.de</email>
</author>
<published>2010-04-28T08:47:36Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e4a95d112e5ea8368bfbdac6ff963d1b8dc63cf0'/>
<id>urn:sha1:e4a95d112e5ea8368bfbdac6ff963d1b8dc63cf0</id>
<content type='text'>
This patch consolidates bootcount_{store|load} for PowerPC by
implementing a common version in arch/powerpc/lib/bootcount.c. This
code is now used by all PowerPC variants that currently have these
functions implemented.

The functions now use the proper IO-accessor functions to read/write the
values.

This code also supports two different bootcount versions:

a) Use 2 separate words (2 * 32bit) to store the bootcounter
b) Use only 1 word (2 * 16bit) to store the bootcounter

Version b) was already used by MPC5xxx.

Signed-off-by: Stefan Roese &lt;sr@denx.de&gt;
Acked-by: Detlev Zundel &lt;dzu@denx.de&gt;
Acked-by: Kim Phillips &lt;kim.phillips@freescale.com&gt;
          for 83xx parts
Cc: Michael Zaidman &lt;michael.zaidman@gmail.com&gt;
Cc: Wolfgang Denk &lt;wd@denx.de&gt;
Cc: Kim Phillips &lt;kim.phillips@freescale.com&gt;
Cc: Anatolij Gustschin &lt;agust@denx.de&gt;
</content>
</entry>
</feed>
