This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Remote debug on ppc405
- From: Robert Schwebel <robert at schwebel dot de>
- To: gdb at sources dot redhat dot com
- Date: Tue, 6 Jan 2004 14:50:48 +0100
- Subject: Remote debug on ppc405
Hi,
I currently try to remote-gdb a program which runs on a ppc405gpr board
and I cannot start it:
----------8<----------8<----------8<----------8<----------8<----------
(gdb) target remote 192.168.1.16:4711
Sending packet: $Hc-1#09...Ack
Packet received: OK
Sending packet: $qC#b4...Ack
Packet received:
Sending packet: $qOffsets#4b...Ack
Packet received:
Sending packet: $?#3f...Ack
Packet received: T0501:7ffffe90;40:3000fba8;
Sending packet: $Hg0#df...Ack
Packet received: OK
Sending packet: $g#67...Ack
Packet received: 000000007ffffe90000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003000fba80000d0320000000000000000000000000000000000000000
Sending packet: $mfffffffc,c#29...Ack
Packet received: ffffffffffffffffffffffff
0x3000fba8 in ?? ()
Sending packet: $m10010920,c8#c1...Ack
Packet received: 00000001000000100000000c100003280000000d100008980000000410000150000000051000022c000000061000018c0000000a000000680000000b0000001000000015000000000000000310010a100000000200000054000000140000000700000017100002d400000007100002c80000000800000060000000090000000c6ffffffe100002a86fffffff000000016ffffff010000294000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
Sending packet: $qSymbol::#5b...Ack
Packet received: qSymbol:5f5f707468726561645f746872656164735f6576656e7473
Packet qSymbol (symbol-lookup) is supported
Sending packet: $qSymbol::5f5f707468726561645f746872656164735f6576656e7473#47...Ack
Packet received: OK
(gdb) si
Sending packet: $Z0,3001b628,4#dc...Ack
Packet received:
Packet Z0 (software-breakpoint) is NOT supported
Sending packet: $m3001b628,4#93...Ack
Packet received: ffffffff
Sending packet: $X3001b628,0:#b4...Ack
Packet received:
binary downloading NOT suppported by target
Sending packet: $M3001b628,4:7d821008#7b...Ack
Packet received: ENN
Sending packet: $M3001b628,4:7d821008#7b...Ack
Packet received: ENN
Warning:
Cannot insert breakpoint -1.
Error accessing memory address 0x3001b628: Input/output error.
(gdb)
----------8<----------8<----------8<----------8<----------8<----------
Looks to me like the PC address (0x3001b628) is not determined correctly;
readelf shows that .text starts at 0x10000350:
----------8<----------8<----------8<----------8<----------8<----------
robert@himalia:~/local/cvs/efco/map-test> powerpc-linux-readelf -S map-test
There are 37 section headers, starting at offset 0x3654:
Section Headers:
[Nr] Name Type Addr Off Size ES Flg Lk Inf Al
[ 0] NULL 00000000 000000 000000 00 0 0 0
[ 1] .interp PROGBITS 10000114 000114 000013 00 A 0 0 1
[ 2] .note.ABI-tag NOTE 10000130 000130 000020 00 A 0 0 16
[ 3] .hash HASH 10000150 000150 00003c 04 A 4 0 4
[ 4] .dynsym DYNSYM 1000018c 00018c 0000a0 10 A 5 1 4
[ 5] .dynstr STRTAB 1000022c 00022c 000068 00 A 0 0 1
[ 6] .gnu.version VERSYM 10000294 000294 000014 02 A 4 0 2
[ 7] .gnu.version_r VERNEED 100002a8 0002a8 000020 00 A 5 1 4
[ 8] .rela.dyn RELA 100002c8 0002c8 00000c 0c A 4 0 4
[ 9] .rela.plt RELA 100002d4 0002d4 000054 0c A 4 18 4
[10] .init PROGBITS 10000328 000328 000028 00 AX 0 0 4
[11] .text PROGBITS 10000350 000350 000548 00 AX 0 0 4
[12] .fini PROGBITS 10000898 000898 000020 00 AX 0 0 4
[13] .rodata PROGBITS 100008b8 0008b8 00005c 00 A 0 0 4
[14] .sdata2 PROGBITS 10000914 000914 000000 00 A 0 0 4
[15] .data PROGBITS 10010914 000914 000008 00 WA 0 0 4
[16] .eh_frame PROGBITS 1001091c 00091c 000004 00 WA 0 0 4
[17] .dynamic DYNAMIC 10010920 000920 0000c8 08 WA 5 0 4
[18] .ctors PROGBITS 100109e8 0009e8 000008 00 WA 0 0 4
[19] .dtors PROGBITS 100109f0 0009f0 000008 00 WA 0 0 4
[20] .jcr PROGBITS 100109f8 0009f8 000004 00 WA 0 0 4
[21] .got PROGBITS 100109fc 0009fc 000014 04 WAX 0 0 4
[22] .sdata PROGBITS 10010a10 000a10 000000 00 WA 0 0 4
[23] .sbss NOBITS 10010a10 000a10 000000 00 WA 0 0 1
[24] .plt NOBITS 10010a10 000a10 00009c 00 WAX 0 0 4
[25] .bss NOBITS 10010aac 000a10 000004 00 WA 0 0 1
[26] .comment PROGBITS 00000000 000a10 00006c 00 0 0 1
[27] .debug_aranges PROGBITS 00000000 000a80 000078 00 0 0 8
[28] .debug_pubnames PROGBITS 00000000 000af8 00001b 00 0 0 1
[29] .debug_info PROGBITS 00000000 000b13 0014b3 00 0 0 1
[30] .debug_abbrev PROGBITS 00000000 001fc6 0001bb 00 0 0 1
[31] .debug_line PROGBITS 00000000 002181 00072f 00 0 0 1
[32] .debug_frame PROGBITS 00000000 0028b0 00002c 00 0 0 4
[33] .debug_str PROGBITS 00000000 0028dc 000c35 01 MS 0 0 1
[34] .shstrtab STRTAB 00000000 003511 000142 00 0 0 1
[35] .symtab SYMTAB 00000000 003c1c 000e60 10 36 63 4
[36] .strtab STRTAB 00000000 004a7c 000a05 00 0 0 1
Key to Flags:
W (write), A (alloc), X (execute), M (merge), S (strings)
I (info), L (link order), G (group), x (unknown)
O (extra OS processing required) o (OS specific), p (processor specific)
----------8<----------8<----------8<----------8<----------8<----------
Any idea?
Robert
--
Dipl.-Ing. Robert Schwebel | http://www.pengutronix.de
Pengutronix - Linux Solutions for Science and Industry
Handelsregister: Amtsgericht Hildesheim, HRA 2686
Hornemannstraße 12, 31137 Hildesheim, Germany
Phone: +49-5121-28619-0 | Fax: +49-5121-28619-4