<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.6944.0">
<TITLE>Debugging U-Boot on arm920t using BDI2000 </TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->
<P><FONT SIZE=2>Hello,<BR>
<BR>
I am developing a custom board with motorola's MX1 processor.<BR>
I have compiled U-Boot successfully for MX1ADS evaluation board<BR>
(it has SyncFlash instead of flash), and this hardware isn't<BR>
very different from mine (only difference is flash). I have studied<BR>
the README and carried out the porting as it is specified, but<BR>
U-Boot doesn't work, or I don't get anything in serial console.<BR>
<BR>
I'm using BDI2000, and when I try to debug U-Boot the code hangs<BR>
in relocate function in start.S file. The exact instruction that hangs the<BR>
gdb is: "sub r2, r3, r2 /* r2 <- size of u-boot */"<BR>
<BR>
1- One problem is that I don't see how the general purpose<BR>
registers (r0, r1...) values change, i.e. when "ldr r0, _start"<BR>
is executed, r0 doesn't change, is this normal? (Is it possible<BR>
to debug start.S with BDI2000?)<BR>
<BR>
When I compile the code,there are no errors or warnings, but a<BR>
UNDEF_SYM appears:<BR>
<BR>
...<BR>
<BR>
make[1]: Leaving directory `/home/iim/IKOR/LinuxEmpotrado/LinCon/\<BR>
build_tools/u-boot/u-boot-1.1.3/common'<BR>
<BR>
UNDEF_SYM=`arm-unknown-linux-gnu-objdump -x lib_generic/libgeneric.a \<BR>
board/LinCon/libLinCon.a cpu/arm920t/libarm920t.a cpu/arm920t/imx/libimx.a \<BR>
lib_arm/libarm.a fs/cramfs/libcramfs.a fs/fat/libfat.a fs/fdos/libfdos.a \<BR>
fs/jffs2/libjffs2.a fs/reiserfs/libreiserfs.a fs/ext2/libext2fs.a net/libnet.a \<BR>
disk/libdisk.a rtc/librtc.a dtt/libdtt.a drivers/libdrivers.a drivers/sk98lin/libsk98lin.a \<BR>
post/libpost.a post/cpu/libcpu.a common/libcommon.a |sed -n -e \<BR>
's/.*\(__u_boot_cmd_.*\)/-u\1/p'|sort|uniq`;\<BR>
<BR>
arm-unknown-linux-gnu-ld -Bstatic -T \<BR>
/home/iim/IKOR/LinuxEmpotrado/LinCon/build_tools/u-boot/u-boot-1.1.3/board/LinCon/u-boot.lds \<BR>
-Ttext 0x08f00000 $UNDEF_SYM cpu/arm920t/start.o \<BR>
<BR>
...<BR>
<BR>
2- When I compile u-boot for my Evaluation Board (MX1ADS),<BR>
this UNDEF_SYM appears, but u-boot works without any problem!<BR>
Is this a problem, or only a "warning"?<BR>
<BR>
Some configuration parameters:<BR>
<BR>
32MB SDRAM -> 0x08000000-0x0A000000<BR>
16MB Flash -> 0x10000000-0x11000000<BR>
<BR>
TEXT_BASE=0x08f00000 (board/<board>/config.mk)<BR>
CFG_MONITOR_BASE=0x10000000 /* flash base addr */(include/configs/<board>.h)<BR>
CFG_MONITOR_LEN=0x20000 (include/configs/<board>.h)<BR>
CFG_LOAD_ADDR=0x08f00000 (include/configs/<board>.h)<BR>
<BR>
arm-linux-objdump -h displays:<BR>
#arm-unknown-linux-gnu-objdump -h u-boot<BR>
<BR>
u-boot: file format elf32-littlearm<BR>
<BR>
Sections:<BR>
Idx Name Size VMA LMA File off Algn<BR>
0 .text 00012f34 08f00000 08f00000 00008000 2**5<BR>
CONTENTS, ALLOC, LOAD, READONLY, CODE<BR>
1 .glue_7 00000000 08f12f34 08f12f34 0001af34 2**2<BR>
CONTENTS, ALLOC, LOAD, READONLY, CODE<BR>
2 .glue_7t 00000000 08f12f34 08f12f34 0001af34 2**2<BR>
CONTENTS, ALLOC, LOAD, READONLY, CODE<BR>
3 .rodata 00000568 08f12f34 08f12f34 0001af34 2**2<BR>
CONTENTS, ALLOC, LOAD, READONLY, DATA<BR>
4 .rodata.str1.4 000042b3 08f1349c 08f1349c 0001b49c 2**2<BR>
CONTENTS, ALLOC, LOAD, READONLY, DATA<BR>
5 .data 00000933 08f17750 08f17750 0001f750 2**2<BR>
CONTENTS, ALLOC, LOAD, DATA<BR>
6 .u_boot_cmd 00000378 08f18084 08f18084 00020084 2**2<BR>
CONTENTS, ALLOC, LOAD, DATA<BR>
7 .bss 00001c2c 08f183fc 08f183fc 000203fc 2**2<BR>
ALLOC<BR>
8 .stab 00000c90 00000000 00000000 000203fc 2**2<BR>
CONTENTS, READONLY, DEBUGGING<BR>
9 .stabstr 0000017d 00000000 00000000 0002108c 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
10 .debug_abbrev 000062dd 00000000 00000000 00021209 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
11 .debug_info 0003bcf1 00000000 00000000 000274e6 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
12 .debug_line 00009f00 00000000 00000000 000631d7 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
13 .debug_frame 00002f6c 00000000 00000000 0006d0d8 2**2<BR>
CONTENTS, READONLY, DEBUGGING<BR>
14 .debug_pubnames 00001845 00000000 00000000 00070044 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
15 .debug_aranges 000005a0 00000000 00000000 00071889 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
16 .debug_str 00003df0 00000000 00000000 00071e29 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
17 .comment 0000033c 00000000 00000000 00075c19 2**0<BR>
CONTENTS, READONLY<BR>
18 .debug_ranges 00000288 00000000 00000000 00075f55 2**0<BR>
CONTENTS, READONLY, DEBUGGING<BR>
<BR>
Any help will be welcomed!!<BR>
<BR>
Thanks in advance.<BR>
<BR>
Ioritz</FONT>
</P>
</BODY>
</HTML>