Hi Boris,<br><br>When you are running the memory test make sure Data cahe and Instruction caches are enabled. <br><br>Also check your BAT setting, there also Cache enable BIT shall be set.<br><br>As the burst transcation will happen only when cache is enabled.
<br><br>How abt ECC...?<br><br>Bhupi<br><br><br><br><div><span class="gmail_quote">On 7/17/07, <b class="gmail_sendername">Boris Shteinbock</b> &lt;<a href="mailto:borish@batm.co.il">borish@batm.co.il</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">






<div>


<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <font size="2">Hi Everyone.<br>
I am working on the Linux port for MPC8347 revision 3 custom build board<br>
with DDR2 memory.<br>
<br>
I&#39;ve successfully ported U-boot (latest git) and the kernel itself,<br>
however during kernel boot I am encountering serious memory corruption<br>
errors. The log for one of the examples is at the bottom of this<br>
message.<br>
<br>
Basically, the corruption is always happening somewhere at memory<br>
management intensive tasks such as networking, JFFS2 mounting etc.<br>
<br>
As far as I can see, it is not related to some specific driver, because<br>
even it happens even at kernel configured at absolute minimum, ( console<br>
serial driver only and even without it)<br>
The place of the corruption depends on kernel configuration.<br>
<br>
The DDR2 memory controller is configured correctly as far as I can tell,<br>
since :<br>
1. DDR2 controller register values are taken from VxWorks bootrom<br>
that works on this board without any problems.<br>
2. u-boot mtest passes successfully<br>
3. u-boot alternative mtest passes successfully<br>
4. My own custom mem tests in u-boot pass successfully<br>
5. If I manage two boot the board into shell prompt (with absolute<br>
minimum configuration) memtester application is also successful.<br>
<br>
The minimum configuration that is one I am able to boot into shell is a<br>
kernel configured with serial console and small busybox JFFS2 file<br>
system in the flash. In this configuration, the boot fails the first<br>
time JFFS2 root FS is mounted. However it does boot after reset.<br>
<br>
I&#39;ve tried different kernels with the same results&nbsp; starting from, I<br>
think, 2.6.16&nbsp; up to 2.6.22<br>
I tried the kernel that is provided by Freescale for 834x reference<br>
boards. ( with my board support of course)<br>
<br>
I tried booting both OF flat trees (powerpc) and bd_t based builds (ppc)<br>
<br>
I&#39;ve also tried all memory management options :<br>
SLAB, SLOB and SLUB (in the latest kernel). They all failed at some<br>
point of time, so the assumption is that the problem is not in the<br>
memory management facilities.<br>
<br>
The board manufacturer swears that DDR2 memory controller values are<br>
correct and should work perfectly.<br>
<br>
So now I almost out of options and I am seeking your help.<br>
Any type of input on this issue would be greatly appreciated.<br>
<br>
Thanks,<br>
Boris<br>
<br>
PS. Note that an below example represents failure during DHCP<br>
autoconfiguration. However the similar error happens even when<br>
networking is disabled completely. just in a different place.<br>
<br>
=&gt; bootm<br>
## Booting image at 00400000 ...<br>
&nbsp;&nbsp; Image Name:&nbsp;&nbsp; Linux-.6.21.5<br>
&nbsp;&nbsp; Created:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2007-07-10&nbsp; 14:20:19 UTC<br>
&nbsp;&nbsp; Image Type:&nbsp;&nbsp; PowerPC Linux Kernel Image (gzip compressed)<br>
&nbsp;&nbsp; Data Size:&nbsp;&nbsp;&nbsp; 898361 Bytes = 877.3 kB<br>
&nbsp;&nbsp; Load Address: 00000000<br>
&nbsp;&nbsp; Entry Point:&nbsp; 00000000<br>
&nbsp;&nbsp; Verifying Checksum ... OK<br>
&nbsp;&nbsp; Uncompressing Kernel Image ... OK<br>
## Current stack ends at 0x07FA3CF8 =&gt; set upper limit to 0x00800000<br>
## cmdline at 0x007FFF00 ... 0x007FFF41<br>
bd address&nbsp; = 0x07FA3FBC<br>
memstart&nbsp;&nbsp;&nbsp; = 0x00000000<br>
memsize&nbsp;&nbsp;&nbsp;&nbsp; = 0x08000000<br>
flashstart&nbsp; = 0xFE000000<br>
flashsize&nbsp;&nbsp; = 0x02000000<br>
flashoffset = 0x00033000<br>
sramstart&nbsp;&nbsp; = 0x00000000<br>
sramsize&nbsp;&nbsp;&nbsp; = 0x00000000<br>
bootflags&nbsp;&nbsp; = 0x00000001<br>
intfreq&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp;&nbsp;&nbsp; 528 MHz<br>
busfreq&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp;&nbsp;&nbsp; 264 MHz<br>
ethaddr&nbsp;&nbsp;&nbsp;&nbsp; = 00:04:9F:EF:23:35<br>
eth1addr&nbsp;&nbsp;&nbsp; = 00:E0:0C:00:7E:25<br>
IP addr&nbsp;&nbsp;&nbsp;&nbsp; = <a href="http://10.2.222.20" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">10.2.222.20</a><br>
baudrate&nbsp;&nbsp;&nbsp; = 115200 bps<br>
No initrd<br>
## Transferring control to Linux (at address 00000000) ...<br>
!!!! of_flat_tree = 00000000<br>
Booting without OF Flat tree<br>
Linux version .6.21.5 (me@localhost) (gcc version<br>
4.0.0 (DENX ELDK 4.1 4.0.0)) #24 Tue Jul 10 17:20:09 IDT 2007<br>
Zone PFN ranges:<br>
&nbsp; DMA&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 -&gt;&nbsp;&nbsp;&nbsp; 32768<br>
&nbsp; Normal&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 32768 -&gt;&nbsp;&nbsp;&nbsp; 32768<br>
early_node_map[1] active PFN ranges<br>
&nbsp;&nbsp;&nbsp; 0:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 -&gt;&nbsp;&nbsp;&nbsp; 32768<br>
Built 1 zonelists.&nbsp; Total pages: 32512<br>
Kernel command line: console=ttyS0,115200 root=/dev/mtdblock1<br>
rootfstype=jffs2 ip=dhcp<br>
IPIC (128 IRQ sources, 8 External IRQs) at fe000700<br>
PID hash table entries: 512 (order: 9, 2048 bytes)<br>
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)<br>
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)<br>
Memory: 127744k available (1584k kernel code, 444k data, 84k init, 0k<br>
highmem)<br>
Mount-cache hash table entries: 512<br>
NET: Registered protocol family 16<br>
Setup MTD partitions<br>
Generic PHY: Registered new driver<br>
NET: Registered protocol family 2<br>
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)<br>
TCP established hash table entries: 4096 (order: 3, 32768 bytes)<br>
TCP bind hash table entries: 4096 (order: 2, 16384 bytes)<br>
TCP: Hash tables configured (established 4096 bind 4096)<br>
TCP reno registered<br>
JFFS2 version 2.2. (NAND) (C) 2001-2006 Red Hat, Inc.<br>
io scheduler noop registered<br>
io scheduler anticipatory registered (default)<br>
io scheduler deadline registered<br>
io scheduler cfq registered<br>
Serial: 8250/16550 driver $Revision: 1.90 $ 2 ports, IRQ sharing<br>
disabled<br>
serial8250.0: ttyS0 at MMIO 0xe0004500 (irq = 9) is a 16550A<br>
serial8250.0: ttyS1 at MMIO 0xe0004600 (irq = 10) is a 16550A<br>
Gianfar MII Bus: probed<br>
eth0: Gianfar Ethernet Controller Version 1.2, 00:04:9f:ef:23:35<br>
eth0: Running with NAPI disabled<br>
eth0: 64/64 RX/TX BD ring size<br>
Broadcom BCM5241: Registered new driver<br>
physmap platform flash device: 02000000 at fe000000<br>
physmap-flash.0: Found 1 x16 devices at 0x0 in 8-bit bank<br>
&nbsp;Amd/Fujitsu Extended Query Table at 0x0040<br>
physmap-flash.0: CFI does not contain boot bank location. Assuming top.<br>
number of CFI chips: 1<br>
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.<br>
cmdlinepart partition parsing not available<br>
RedBoot partition parsing not available<br>
Using physmap partition information<br>
Creating 2 MTD partitions on &quot;physmap-flash.0&quot;:<br>
0x00000000-0x00100000 : &quot;uboot&quot;<br>
0x00100000-0x02000000 : &quot;rootfs&quot;<br>
IPv4 over IPv4 tunneling driver<br>
GRE over IPv4 tunneling driver<br>
TCP cubic registered<br>
NET: Registered protocol family 1<br>
NET: Registered protocol family 17<br>
!!!! Gianfar init_phy. phy_id = 0:01<br>
!!!! phy_attach. phy_id = 0:01<br>
!!!! phy_attach device found. phy_id = 0:01<br>
Sending DHCP requests .&lt;3&gt;slab: Internal list corruption detected in<br>
cache &#39;files_cache&#39;(21), slabp c0344000(16). Hexdump:<br>
<br>
000: 00 10 01 00 00 20 02 00 00 00 00 70 c0 34 40 70<br>
010: 00 00 00 10 00 00 ff 10 00 00 00 00 ff ff ff fe<br>
020: ff ff ff fe ff ff ff fe ff ff ff fe ff ff ff fe<br>
030: ff ff ff fe ff ff ff fe ff ff ff fe ff ff ff fe<br>
040: ff ff ff fe ff ff ff fe ff ff ff fe ff ff ff fe<br>
050: ff ff ff fe ff ff ff fe ff ff ff fd 00 00 00 11<br>
060: 00 00 00 12 00 00 00 13 00 00 00 14 ff ff ff ff<br>
------------[ cut here ]------------<br>
kernel BUG at mm/slab.c:2936!<br>
Oops: Exception in kernel mode, sig: 5 [#1]<br>
NIP: C0050F80 LR: C0050F80 CTR: 00000000<br>
REGS: c034fe00 TRAP: 0700&nbsp;&nbsp; Not tainted&nbsp; (.6.21.5)<br>
MSR: 00021032 &lt;ME,IR,DR&gt;&nbsp; CR: 24004002&nbsp; XER: 00000000<br>
TASK = c032a3c0[3] &#39;events/0&#39; THREAD: c034e000<br>
GPR00: C0050F80 C034FEB0 C032A3C0 00000001 00000DF5 FFFFFFFF C00F5B54<br>
00000010<br>
GPR08: C01D0000 C01E0000 00000DF5 00000DF5 00000000 00F1C5DB 07FFD000<br>
FFFFFFFF<br>
GPR16: 00000001 00000000 00000000 00800000 00000000 007FFF00 00000000<br>
C033DAA0<br>
GPR24: C0339C90 00000007 00000000 C01B0000 C01B0000 C0344000 C033DAA0<br>
00000070<br>
NIP [C0050F80] check_slabp+0xe4/0x11c<br>
LR [C0050F80] check_slabp+0xe4/0x11c<br>
Call Trace:<br>
[C034FEB0] [C0050F80] check_slabp+0xe4/0x11c (unreliable)<br>
[C034FED0] [C0051450] free_block+0x88/0x138<br>
[C034FF00] [C0052188] drain_array+0xa0/0xe0<br>
[C034FF20] [C0052228] cache_reap+0x60/0x144<br>
[C034FF40] [C00257B0] run_workqueue+0xd0/0x170<br>
[C034FF60] [C0025960] worker_thread+0x110/0x144<br>
[C034FFC0] [C00298E4] kthread+0x74/0xb0<br>
[C034FFF0] [C0005F38] kernel_thread+0x44/0x60<br>
Instruction dump:<br>
387b6538 7c9df8ae 4bfc2b49 3bff0001 813e0020 5529103a 3929001c 7f9f4840<br>
419cffcc 3c60c01b 3863336c 4bfc2b25 &lt;0fe00000&gt; 48000000 80030020<br>
2f800000<br>
</font>
</p>

</div>
<br>_______________________________________________<br>Linuxppc-embedded mailing list<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Linuxppc-embedded@ozlabs.org">Linuxppc-embedded@ozlabs.org</a>
<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="https://ozlabs.org/mailman/listinfo/linuxppc-embedded" target="_blank">https://ozlabs.org/mailman/listinfo/linuxppc-embedded</a><br></blockquote></div><br>