<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/arch/microblaze/cpu, branch v2010.09</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>Make sure that argv[] argument pointers are not modified.</title>
<updated>2010-07-04T21:55:42+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2010-06-28T20:00:46+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=54841ab50c20d6fa6c9cc3eb826989da3a22d934'/>
<id>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>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Consolidate cache code</title>
<updated>2010-04-16T10:56:33+00:00</updated>
<author>
<name>Michal Simek</name>
<email>monstr@monstr.eu</email>
</author>
<published>2010-04-16T10:56:33+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8ff972c6e99938f1a033e5500dccc9a37ce3406f'/>
<id>8ff972c6e99938f1a033e5500dccc9a37ce3406f</id>
<content type='text'>
Merge cpu and lib cache code.
Flush cache before disabling.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Merge cpu and lib cache code.
Flush cache before disabling.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Fix interrupt handler code</title>
<updated>2010-04-16T10:15:34+00:00</updated>
<author>
<name>Michal Simek</name>
<email>monstr@monstr.eu</email>
</author>
<published>2010-04-16T09:51:59+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8125c980cc282000cbddb415f8ddbebf96e4edb4'/>
<id>8125c980cc282000cbddb415f8ddbebf96e4edb4</id>
<content type='text'>
It is better to read ivr and react on it than do long parsing from
two regs. Interrupt controller returs actual irq number.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is better to read ivr and react on it than do long parsing from
two regs. Interrupt controller returs actual irq number.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Move FSL initialization to board.c</title>
<updated>2010-04-16T10:15:33+00:00</updated>
<author>
<name>Michal Simek</name>
<email>monstr@monstr.eu</email>
</author>
<published>2010-04-16T09:43:43+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=b26640971a7ba8800f0eb32af145ff0727fe21fe'/>
<id>b26640971a7ba8800f0eb32af145ff0727fe21fe</id>
<content type='text'>
Move FSL out of interrupt controller.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Move FSL out of interrupt controller.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Move timer initialization to board.c</title>
<updated>2010-04-16T10:15:31+00:00</updated>
<author>
<name>Michal Simek</name>
<email>monstr@monstr.eu</email>
</author>
<published>2010-04-16T09:37:41+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5bbcb6cf22b1121d8c3e56b0e1fb84366e903ac7'/>
<id>5bbcb6cf22b1121d8c3e56b0e1fb84366e903ac7</id>
<content type='text'>
I would like to handle case where system doesn't contain
intc that's why I need timer initialization out of intc code.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I would like to handle case where system doesn't contain
intc that's why I need timer initialization out of intc code.

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Fix irq.S code</title>
<updated>2010-04-16T10:15:30+00:00</updated>
<author>
<name>Michal Simek</name>
<email>monstr@monstr.eu</email>
</author>
<published>2010-04-16T09:30:16+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=cc53690e05f47b4c25e0a528de50e024fc0164ad'/>
<id>cc53690e05f47b4c25e0a528de50e024fc0164ad</id>
<content type='text'>
It is ancient code. There is possible to save several instructions
just if we use offset instead of addik

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is ancient code. There is possible to save several instructions
just if we use offset instead of addik

Signed-off-by: Michal Simek &lt;monstr@monstr.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>microblaze: Move cpu/microblaze/* to arch/microblaze/cpu/*</title>
<updated>2010-04-13T07:13:26+00:00</updated>
<author>
<name>Peter Tyser</name>
<email>ptyser@xes-inc.com</email>
</author>
<published>2010-04-13T03:28:16+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=6260fb0458d94c83aa5b180745b1946c0c94d364'/>
<id>6260fb0458d94c83aa5b180745b1946c0c94d364</id>
<content type='text'>
Signed-off-by: Peter Tyser &lt;ptyser@xes-inc.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Peter Tyser &lt;ptyser@xes-inc.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
