Skip to contentSkip to conversation

ECC DIMM's with walnut board

U-Boot-Users Thomas Schäfer 3 participants 3 messages Apr 28, 2003 – May 22, 2003

lore
Share & tools
lore
#0 lore raw

Hi all,

I tried to boot a walnut board with a 256 ECC DIMM using u-boot 0.3.0, but didn't succeed. When examining the code in the function spd_sdram in cpu/ppc4xx/spd_sdram, I found that the ECC configuration code is probably wrong. I suppose, that the following lines

	/* now check for ECC ability of module. We only support ECC
	 *   on 32 bit wide devices with 8 bit ECC.
	 */
	if ( (read_spd(11)==2) && ((read_spd(6)==40) || (read_spd(14)==8)) ){
	   sdram0_ecccfg=0xf<<SDRAM0_ECCCFG_SHIFT;
	   ecc_on = 1;

should be replaced with

	/* now check for ECC ability of module. We only support ECC
	 *   on 32 bit wide devices with 8 bit ECC.
	 */
==>	if ( (read_spd(11)==2) && ((read_spd(6)==40) &&
read_spd(14)==8)) ){ <==
	   sdram0_ecccfg=0xf<<SDRAM0_ECCCFG_SHIFT;
	   ecc_on = 1;

The reason is, that the if statement in the first code is also true for 72 bit ECC devices. So ECC is enabled for such a device which fails in the following. The changed code works for me with several DIMM types (32MB without ECC, 256 MB with ECC and without ECC), but I'm not an expert with all types of SDRAM and so I'm not sure if I fully understood the code in that place. Any ideas, comments?

Best regards

Thomas Sch?fer

____________________________________

GIGA STREAM - UMTS Technologies GmbH

Konrad-Zuse-Str. 7
66115 Saarbr?cken

Tel.: + 49 (0)681 / 95916 - 203
Fax: + 49 (0)681 / 95916 - 100
E-mail: [email protected]

#1 lore raw
Quoted 7 lines · Thomas Sch?fer

Hi all,

following. The changed code works for me with several DIMM types (32MB without ECC, 256 MB with ECC and without ECC), but I'm not an expert with all types of SDRAM and so I'm not sure if I fully understood the code in that place. Any ideas, comments?

Quoted 5 lines

Best regards

Thomas Sch?fer

This clearly changes nothing for non ECC dimms and you are the first I heard of using ecc so you are probably right :)

Do a proper patch and send it over to Wolfgang. You could take out a few more parentheses

Signature · 4 lines
Kenneth Johansson	
Ericsson AB                       Tel: +46 8 719 70 20
Tellusborgsv?gen  90              Fax: +46 8 719 29 45
126 25 Stockholm                  ken at switchboard.ericsson.se
#2 lore raw
In reply to Thomas Schäfer

Dear Thomas,

Quoted 6 lines · in message <[email protected]> you wrote:

I tried to boot a walnut board with a 256 ECC DIMM using u-boot 0.3.0, bu= t
didn't succeed. When examining the code in the function spd_sdram in cpu/ppc4xx/spd_sdram, I found that the ECC configuration code is probably wrong. I suppose, that the following lines

I was waiting for a regular patch, but obviously you won't send one.

So I added this now manually.

Best regards,

Wolfgang Denk

Signature · 3 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Sorry, but my karma just ran over your dogma.