[U-Boot-Users] starting with u-boot

Hi,
I am a newbie to u-boot as well as embedded system development, I have problem to port u-boot to my board.
I have a customized board with Motorola MC9328MXL processor, which is the same as mx1ads board. The hardware configurations as below:
CPU: Motorola Dragon Ball MXL microcontroller (ARM920T CPU Core) CPU Core speed 192MHZ and System Speed 96MHz
RAM: 8M bytes Ram address: 0x08000000 ---- 0x08800000
Flash: 2M Bytes For bootup, 0x00000000 -- 0x00200000 For normal working, 0x10000000 -- 0x10200000
I/O: 1 Serial at UART 1 1 USB slave No Ethernet
According to the above configs, I did the following modification to mx1ads.h
#define CFG_MEMTEST_START 0x08100000 /* memtest works on */ #define CFG_MEMTEST_END 0x08800000 /* 7 MB in DRAM */
#define CFG_LOAD_ADDR 0x08400000 /* default load address */
/*----------------------------------------------------------------------- * Physical Memory Map */
#define CONFIG_NR_DRAM_BANKS 1 /* we have 1 bank of SDRAM */ #define PHYS_SDRAM_1 0x08000000 /* SDRAM on CSD0 */ #define PHYS_SDRAM_1_SIZE 0x00800000 /* 8 MB */
#define CFG_MAX_FLASH_BANKS 1 /* 1 bank of SyncFlash */ #define CFG_FLASH_BASE 0x00000000 /* SyncFlash on CSD1 */ #define FLASH_BANK_SIZE 0x00200000 /* 2 MB Total */
/*----------------------------------------------------------------------- * FLASH and environment organization */
#define CONFIG_SYNCFLASH 1 #define PHYS_FLASH_SIZE 0x00200000 #define CFG_MAX_FLASH_SECT (8) #define CFG_ENV_ADDR (CFG_FLASH_BASE+0x00080000)
#define CFG_ENV_IS_IN_FLASH 1 #define CFG_ENV_SIZE 0x04000 /* Total Size of Environment Sector */ #define CFG_ENV_SECT_SIZE 0x040000
After compilation, I download the u-boot.bin to 0x08000000 with Trace32 Then set PC to 0x08000000 and run
But how can I know it running ok? The serial port doesn't have any data ( I monitored with oscilloscope) And from the Trace32 Debugger, the CPU will keep looping at some point.

Zhu Yong zhu.mm.yong@gmail.com wrote:
After compilation, I download the u-boot.bin to 0x08000000 with Trace32 Then set PC to 0x08000000 and run
Pls try to program your u-booot.bin into FLASH and debug from there. The method of loading the image into
RAM to debug isn't recommonded to a newbie of U-Boot.
But how can I know it running ok? The serial port doesn't have any data ( I monitored with oscilloscope)
Well, the method you used made yourself on your own. It shouldn't be surprised.
Pls try to avoid posting HTML message to this list. Only PLAIN TEXT is welcome.
===== Best regards,
Sam
_________________________________________________________ Do You Yahoo!? 150万曲MP3疯狂搜,带您闯入音乐殿堂 http://music.yisou.com/ 美女明星应有尽有,搜遍美图、艳图和酷图 http://image.yisou.com 1G就是1000兆,雅虎电邮自助扩容! http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1...

Now I burn the u-boot.bin into flash.
After reset the board, code stopped after some running. I know that U-boot will copy code from flash to RAM after startup, but how do I know if the data copied correctly?
Because I set TEXT_BASE to 0x08400000, I dumped data from flash as well as RAM (from 0x08400000) with length equal to the size of u-boot.bin, the two file are totally different.
From Trace32 Data.list, the code from both flash and RAM are valid, which
means don't have any undefined command.
Here is my question: If content in flash and RAM are totally different, does it mean my RAM not initialized correctly? Or they are supposed to be different?
The stop address is ldr pc, _data_abort in start.S
What's the possible reason to stuck at data_abort?
----- Original Message ----- From: "Sam Song" samsongshu@yahoo.com.cn To: "Zhu Yong" zhu.mm.yong@gmail.com; u-boot-users@lists.sourceforge.net Sent: Friday, January 14, 2005 12:36 PM Subject: Re: [U-Boot-Users] starting with u-boot
Zhu Yong zhu.mm.yong@gmail.com wrote:
After compilation, I download the u-boot.bin to 0x08000000 with Trace32 Then set PC to 0x08000000 and run
Pls try to program your u-booot.bin into FLASH and debug from there. The method of loading the image into
RAM to debug isn't recommonded to a newbie of U-Boot.
But how can I know it running ok? The serial port doesn't have any data ( I monitored with oscilloscope)
Well, the method you used made yourself on your own. It shouldn't be surprised.
Pls try to avoid posting HTML message to this list. Only PLAIN TEXT is welcome.
===== Best regards,
Sam
Do You Yahoo!? 150万曲MP3疯狂搜,带您闯入音乐殿堂 http://music.yisou.com/ 美女明星应有尽有,搜遍美图、艳图和酷图 http://image.yisou.com 1G就是1000兆,雅虎电邮自助扩容!
http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1 g/

In message 000a01c4fa26$7c202840$a1b9a8c0@ZhuYong you wrote:
Now I burn the u-boot.bin into flash.
Good.
After reset the board, code stopped after some running.
Analyze the "some running" part.
I know that U-boot will copy code from flash to RAM after startup, but how do I know if the data copied correctly?
Rn the code under the debugger. You got a Trace32. This is a very expensive tool (you can get several BDI2000's for it), so make use of it. Set break points, single step etc. Use the tools you got.
If content in flash and RAM are totally different, does it mean my RAM not initialized correctly? Or they are supposed to be different?
Naybe the code just crashed before copying the code, maybe anything else happened. How could we know? It is YOU who is sitting in front of a high-tech debugger. USE IT!!
What's the possible reason to stuck at data_abort?
This can be anything. Debug your code.
Best regards,
Wolfgang Denk

Zhu Yong zhu.mm.yong@gmail.com wrote:
Because I set TEXT_BASE to 0x08400000, I dumped data from flash as well as RAM (from 0x08400000) with length equal to the size of u-boot.bin, the two file are totally different.
Seems wrong to me.
#define CFG_FLASH_BASE 0x00000000 /* SyncFlash on
CSD1 */
#define FLASH_BANK_SIZE 0x00200000 /* 2 MB Total
*/
You should set TEXT_BASE in the scope of 0x200000, one address which reset vector locates in FLASH according to your hardware configuration.
Read the DOC Wolfgang suggested and search some related threads in this maillist archive and try:-)
Good Luck!
===== Best regards,
Sam
_________________________________________________________ Do You Yahoo!? 150万曲MP3疯狂搜,带您闯入音乐殿堂 http://music.yisou.com/ 美女明星应有尽有,搜遍美图、艳图和酷图 http://image.yisou.com 1G就是1000兆,雅虎电邮自助扩容! http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1...

I'm pretty sure TEXT_BASE should be set to the beginning of U-Boot. I am assuming that you are running from Flash. The TEXT_BASE you have set is 132 MB from the start of flash, which is only 2 MB. So I'm not sure what you are hitting at 0x08400000 (depends on your memory map). So I would set TEXT_BASE to wherever you are programming u-boot.bin to. For example in my system I have 128 MB of flash residing at 0xf8000000. I program U-Boot starting at 0xfff80000. So my TEXT_BASE is set to 0xfff80000.
Hope it helps!
Jeff Stevens
--- Sam Song samsongshu@yahoo.com.cn wrote:
Zhu Yong zhu.mm.yong@gmail.com wrote��
Because I set TEXT_BASE to 0x08400000, I dumped
data
from flash as well as RAM (from 0x08400000) with length equal to the size of u-boot.bin, the two file are totally different.
Seems wrong to me.
#define CFG_FLASH_BASE 0x00000000 /* SyncFlash on
CSD1 */
#define FLASH_BANK_SIZE 0x00200000 /* 2 MB Total
*/
You should set TEXT_BASE in the scope of 0x200000, one address which reset vector locates in FLASH according to your hardware configuration.
Read the DOC Wolfgang suggested and search some related threads in this maillist archive and try:-)
Good Luck!
===== Best regards,
Sam
_________________________________________________________
Do You Yahoo!? 150����MP3����ѣ������������ֵ��� http://music.yisou.com/ ��Ů����Ӧ�о��У��ѱ���ͼ����ͼ�Ϳ�ͼ http://image.yisou.com 1G����1000�ף��Ż������������ݣ�
http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1...
-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt _______________________________________________ U-Boot-Users mailing list U-Boot-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/u-boot-users
__________________________________ Do you Yahoo!? The all-new My Yahoo! - What will yours do? http://my.yahoo.com

On Saturday 15 January 2005 08:18 am, Jeff Stevens wrote:
So I would set TEXT_BASE to wherever you are programming u-boot.bin to. For example in my system I have 128 MB of flash residing at 0xf8000000. I program U-Boot starting at 0xfff80000. So my TEXT_BASE is set to 0xfff80000.
Zhu Yong zhu.mm.yong@gmail.com wrote
You should set TEXT_BASE in the scope of 0x200000, one address which reset vector locates in FLASH according to your hardware configuration.
What you describe may be how it works for PPC platforms but not for ARM.
For the ARM platforms, TEXT_BASE is the location of U-Boot in RAM. You program the binary to the location your cpu executes on reset...the start of a flash bank. This is for the few arm920 based SoCs I've worked on or seen.

Hi ,
I need to load my new uboot image from SDRAM , not from Flash. Is that possible and how can i do that?
Also , if this discussion has been done before, that would be great if someone replies me with the link.
Regards, Alireza Sadri.
__________________________________ Do you Yahoo!? The all-new My Yahoo! - What will yours do? http://my.yahoo.com

Hi ,
I need to load my new uboot image from SDRAM , not from Flash. Is that possible and how can i do that?
And where does the SDRAM gets it u-boot image from???? So you have to load it into SDRAM first after every power-up?
And load from SDRAM to where? SDRAM???
Makes absolutely no sense to me (o;
Also , if this discussion has been done before, that would be great if someone replies me with the link.
Maybe time for you telling about your board specs and your intention why to do it this strange way?
rick

Alireza Sadri wrote:
Hi ,
I need to load my new uboot image from SDRAM , not from Flash. Is that possible and how can i do that?
Also , if this discussion has been done before, that would be great if someone replies me with the link.
Regards, Alireza Sadri.
Read the FAQ on the subject: http://www.denx.de/twiki/bin/view/DULG/CanUBootBeConfiguredSuchThatItCanBeStartedInRAM
gvb

In message 20050117152203.76982.qmail@web12822.mail.yahoo.com you wrote:
I need to load my new uboot image from SDRAM , not from Flash. Is that possible and how can i do that?
This is possible, but not supported.
Also , if this discussion has been done before, that would be great if someone replies me with the link.
No. It's the other way round. _You_ are supposed to read the documentation and especially the FAQ section _before_ posting here.
See http://www.denx.de/twiki/bin/view/DULG/CanUBootBeConfiguredSuchThatItCanBeSt...
Wolfgang Denk

On Mon, 17 Jan 2005 07:22:03 -0800 (PST), Alireza Sadri arsadri@yahoo.ca wrote:
I need to load my new uboot image from SDRAM , not from Flash. Is that possible and how can i do that?
Yes this is possible, however in most cases not a good idea (See the links to the FAQs already posted.)
I've done this with our platform as we only have 4KB able to be booted from (much much too small for U-Boot.) So we have a primary bootloader that comes up on boot, does all board and processor initialization (including TLB's and SDRAM) required for the platform and then loads a modified version of U-Boot into SDRAM.
In this case, U-Boot is only used as a ROM Loader and does not handle many of the tasks that it would normally handle to normally bring-up the board. Additionally, in this case, the U-Boot Loader running from SDRAM CANNOT be used as the only boot agent and will require another boot agent to load it.
Regards,

In message 001701c4f9ed$b51d2cd0$a1b9a8c0@ZhuYong you wrote:
I am a newbie to u-boot as well as embedded system development, I have problem to port u-boot to my board.
Especially as a newbee you are expected to read the documentation (README, DULG, and especially the FAQ section) _before_ posting.
After compilation, I download the u-boot.bin to 0x08000000 with Trace32 Then set PC to 0x08000000 and run
This is a FAQ. What you are doing is explicitely unsupported. See http://www.denx.de/twiki/bin/view/DULG/CanUBootBeConfiguredSuchThatItCanBeSt...
Content-Type: text/html; charsetÿb2312" Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
And please NEVER post HTML to this list.
Best regards,
Wolfgang Denk
participants (9)
-
Alireza Sadri
-
Bradley Remedios
-
Jeff Stevens
-
Jerry Van Baren
-
Paul Ruhland
-
richard@uclinux.net
-
Sam Song
-
Wolfgang Denk
-
Zhu Yong