From: Cliff Brake <cliff.brake@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] debugging U-boot with GDB on a Au1550
Date: Mon, 18 Jul 2005 08:38:54 -0500 [thread overview]
Message-ID: <f96d234e050718063874086054@mail.gmail.com> (raw)
In-Reply-To: <20050716213807.8E1ED35262A@atlas.denx.de>
On 7/16/05, Wolfgang Denk <wd@denx.de> wrote:
> In message <f96d234e05071614186ad9526a@mail.gmail.com> you wrote:
> >
> > most ARM platforms are linked to the RAM location. After U-boot is
> > relocated to RAM, how do I tell GDB what the new link address is
> > (0x80fdc000 in this case)?
>
> May I suggest that you start reading the manual? Especially section
> http://www.denx.de/twiki/bin/view/DULG/DebuggingUBoot#Section_10.1.2.
Thanks for the suggestion -- very helpful. Things still are not
working for me. Setup:
- Au1550
- U-boot CVS tip
- using MIPS toolchain from ELDK 3.3.1
- BDI2000
When I try to reload the symbol files after re-location into RAM, GDB
still does not seem to be able to sync up to source code (see
transcript below). Also, when I do "mips-linux-objdump -dS u-boot",
the result does not include C code mixed w/ ASM. This does work when
building u-boot for ARM. Does anyone have any suggestions?
Another strange thing w/ GDB, when I type "break <function name>" the
resulting breakpoint is 10 instructions past the start of the
function.
Thanks,
Cliff
GDB transcript:
cbrake at notebook ~/workspace/u-boot $ mips-linux-gdb u-boot
Warning: Cannot initialize solib-absolute-prefix
GNU gdb Yellow Dog Linux (5.2.1-4b_8)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "--host=i386-redhat-linux --target=mips-linux"...
(gdb) symbol-file
Discard symbol table from `/home/cbrake/workspace/u-boot/u-boot'? (y or n) y
No symbol file now.
(gdb) add-symbol-file u-boot 0x80fdc000
add symbol table from file "u-boot" at
.text_addr = 0x80fdc000
(y or n) y
Reading symbols from u-boot...done.
(gdb) target remote bdi:2001
Remote debugging using bdi:2001
0x80fdd158 in ?? ()
(gdb) break printf
Breakpoint 1 at 0x80fe9ecc: file console.c, line 225.
(gdb) ni
Program received signal SIGABRT, Aborted.
warning: Warning: GDB can't find the start of the function at 0x80fdd15c.
GDB is unable to find the start of the function at 0x80fdd15c
and thus can't determine the size of that function's stack frame.
This means that GDB may be unable to access that stack frame, or
the frames below it.
This problem is most likely caused by an invalid program counter or
stack pointer.
However, if you think GDB should simply search farther back
from 0x80fdd15c for code which looks like the beginning of a
function, you can increase the range of the search using the `set
heuristic-fence-post' command.
0x80fdd15c in ?? ()
--
=======================
Cliff Brake
http://bec-systems.com
next prev parent reply other threads:[~2005-07-18 13:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-16 21:18 [U-Boot-Users] debugging U-boot with GDB on a Au1550 Cliff Brake
2005-07-16 21:38 ` Wolfgang Denk
2005-07-18 13:38 ` Cliff Brake [this message]
2005-08-22 19:24 ` Cliff Brake
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f96d234e050718063874086054@mail.gmail.com \
--to=cliff.brake@gmail.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox