Re: [U-Boot-Users] A question about sdram_init

Frank, frankly: you must learn to give us some more information if you expect useful replies.
OK, the system I am using is PPC405 custom board. The board is same as WALNUT but install a special purpose I/F in ASIC. That's why I said it is similiar as WALNUT. Since that part won't interfere others, it can be considered same as WALNUT. The board has 8M bytes SDRAM installed. SDRAM address space is 0x0-0x7FFFFFFF. Flast ROM address space is 0xFFC00000 - 0xFFFFFFFF.
- The sdram() hanged after 2nd line, i.e. after set up 4MB. But it
didn't
go through 3rd line and didn't return.
For example, until now you didn't bother to tell us which source file you are talking about. or what are the characteristics of your board. "similiar as WALNUT"? This doesn't mean anything.
Sorry, wrong function name. I've corrected in the second post. The problem happens in cpu/ppc4xx/sdram.c -> sdram_init().
I don't have a debugger. But I do have LEDs on the board, so I simply
use
Get a debugger, so you can singlestep, check register and memory contents, etc.
I know. But my boss keep saying learnning to use the debugger is time-consuming and refused to buy a debugger for me, which really pissed me off. Sigh... But this is the reality - I don't have a debugger and have to have to have the u-boot run on my system within one week...
How do you know your code is correct?
I didn't write any code. All these three lines were in original sdram_init(). Original sdram_init() tried to detect sdram with different
Which source file are you talking about? cpu/ppc4xx/sdram.c? or cpu/ppc4xx/spd_sdram.c? or what?
cpu/ppc4xx/sdram.c
BTW, I commented out udelay(200). But I don't think it will have any
affect.
Why did you do that? RAM chips may have a power on delay. Did you read the RAM manufacturer's users manual?
Well, my purpose is just to find out why the 3rd instructions can not get through. So I just strip everything which is temporary is not related to this purpose. Do you think udelay can be a cause? I really doubt it because I've tried both occasions but none of them works.
Thanks!
Frank
_________________________________________________________________ Is your PC infected? Get a FREE online computer virus scan from McAfee® Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963

In message BAY2-F138np7Y5pnryM00015182@hotmail.com you wrote:
OK, the system I am using is PPC405 custom board. The board is same as WALNUT but install a special purpose I/F in ASIC. That's why I said it is similiar as WALNUT. Since that part won't interfere others, it can be considered same as WALNUT. The board has 8M bytes SDRAM installed. SDRAM
Does it use exactly the same RAM chips as the walnut?
I know. But my boss keep saying learnning to use the debugger is time-consuming and refused to buy a debugger for me, which really pissed me
Your boss is of course right. Learning how to use a debugger is time-consuming.
Maybe nobody told him that working without a debugger is even more time-consuming, and he will lose this time again and again, while the learning part is needed only once.
off. Sigh... But this is the reality - I don't have a debugger and have to have to have the u-boot run on my system within one week...
This is probably where he "hire a guru" part of the porting guide kicks in.
Well, my purpose is just to find out why the 3rd instructions can not get through. So I just strip everything which is temporary is not related to this purpose. Do you think udelay can be a cause? I really doubt it because I've tried both occasions but none of them works.
U-Boot doesn't work this way. I think it will be very difficult to get it working when you stumble from line to line, without tools or understanding what's going on. There is a 95% chance that after solving this problem, your system will hang during or after relo- cation to RAM.
Try to understand what the code is doing, and if it actually fits your hardware.
BTW: are you absolutely sure your hardware is working at all?
Best regards,
Wolfgang Denk
participants (2)
-
Frank Young
-
Wolfgang Denk