From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22163 invoked by alias); 24 Sep 2004 21:57:46 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 22126 invoked from network); 24 Sep 2004 21:57:43 -0000 Received: from unknown (HELO zmaex.zma.zoran.com) (206.67.17.2) by sourceware.org with SMTP; 24 Sep 2004 21:57:43 -0000 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: Remote communication error Date: Fri, 24 Sep 2004 21:57:00 -0000 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: From: "Lan Zhang" To: X-SW-Source: 2004-09/txt/msg00222.txt.bz2 Yes, I set the debug serial to 1, but I cannot see any clue from that. It just stopped there when it tries to read a memory, and it didn't depend on the memory address, it could stop at any address. And it also stopped sometime when host try to get response for "$s#" packet, and pop out same message.=20 I tried to change remotetimeout value, and it didn't help also.=20 I think it could be USB buffer problem on host. But I have no idea how to debug this debugger bug and how to check the USB in and out buffer. By the way, I am not using the standard GDB, my target is arm processor, and I used armcc compiler, so I check out some version which works for this special symbol table from CVS.=20 What can I do? Thanks a lot.=20 Lan (gdb-usb) r usbname name=3D /dev/usb/lp0=20 ops->name =3D usb usb open Found TI** device Sending packet: $Hc-1#09...Ack Packet received: T050f:4cc30e00;0d:7c066300; Sending packet: $qC#b4...Ack Packet received:=20 Sending packet: $qOffsets#4b...Ack Packet received:=20 Sending packet: $?#3f...Ack Packet received:=20 target_terminal_ours () warning: Invalid remote reply:=20 Packet received: S05 target_wait (-1, status) =3D 42000, status->kind =3D stopped, signal =3D SIGTRAP Sending packet: $Hg0#df...Ack Packet received: OK Sending packet: $g#67...Ack Packet received: 0000000013000060c0445b00000000001600000000000000010000000100000000000000 0000000038c7620034076300a50affff7c066300a8df09004cc30e001300002013000020 target_fetch_registers (pc) =3D 4cc30e00 0xec34c 967500 target_terminal_ours_for_output () target_terminal_ours () FirstMode () at ../fp/fp.c:1054 remote name line 2280 =3D /dev/usb/lp0 (gdb-usb) set debug serial 1 (gdb-usb) n Sending packet: $mec2b0,4#59...[+]Ack [$][0][4][e][0][2][d][e][5][#][2][9]Packet received: 04e02de5 target_xfer_memory (0xec2b0, xxx, 4, read, xxx) =3D 4, bytes =3D 04 e0 2d e5 Sending packet: $mec2b4,4#5d...[+]Ack [$][2][c][d][0][4][d][e][2][#][5][8]Packet received: 2cd04de2 target_xfer_memory (0xec2b4, xxx, 4, read, xxx) =3D 4, bytes =3D 2c d0 4d e2 ... ... ... Sending packet: $mec2c8,4#62...[+]Ack [$][1][4][0][0][9][d][e][5][#][f][c]Packet received: 14009de5 target_xfer_memory (0xec2c8, xxx, 4, read, xxx) =3D 4, bytes =3D 14 00 9d e5 Sending packet: $mec2cc,4#8d...[+]Ack [$][0][0][0][0][5][0][e][3][#][b][d]Packet received: 000050e3 target_xfer_memory (0xec2cc, xxx, 4, read, xxx) =3D 4, bytes =3D 00 00 50 e3 Sending packet: $mec2d0,4#5b...[]target_terminal_ours () Remote communication error: Connection timed out. Sending packet: $z0,ec394,4#9e...[]target_terminal_ours () Remote communication error: Connection timed out. (gdb-usb)=20 FROM GDB log: w +$Hc-1#09 r +$T050f:4cc30e00;0d:7c066300;#b8 w +$qC#b4 r +$#00 w +$qOffsets#4b r +$#00 w +$?#3f r +$#00 w + r +$S05#b8 w +$Hg0#df r +$OK#9a w +$g#67 r +$0000000013000060c0445b000000000016000000000000000100000001000000000000 000000000038c7620034076300a50affff7c066300a8df09004cc30e0013000020130000 20#cb w + c set debug serial 1 c n w $mec2b0,4#59 r +$04e02de5#29 w +$mec2b4,4#5d ... ... ... w +$mec2cc,4#8d r +$000050e3#bd w +$mec2d0,4#5b r w $z0,ec394,4#9e r -----Original Message----- From: Andrew Cagney [mailto:cagney@gnu.org]=20 Sent: Friday, September 24, 2004 4:49 PM To: Lan Zhang Cc: gdb@sources.redhat.com Subject: Re: Remote communication error > Hi, >=20 > I set up a remote debug using USB port. I got some message like:=20 > Remote communication error: Connection timed out. And this can happen=20 > at the begin of the debug or after I already did some debug commands.=20 > But the whole remote debug works fine for the serial port. I think I=20 > didn't add USB interface correctly. Could anyone point me which code=20 > related to the remote communication error, and why this happens? >=20 > Thanks a lot That it works with a simple serial device and not USB suggests a bug in=20 the kernel or h/w. GDB (assuming this is with a standard GDB) uses=20 identical code to drive both devices. You can use "(gdb) set debug serial" to see exactly what GDB is doing=20 when it hangs. ANdrew