This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: remote protocol patch


On Wed, Jan 16, 2008 at 11:11:26AM +0100, Zoltán Filyó wrote:
> 
> Hi,
> 
> I found that the serial remote protocol runs into a deadlock when
> the serial line is noisy. Below a gdb log fragment with original
> code:

My strong recommendation is to not use the GDB serial protocol over a
noisy line.  There's other problems, for instance with packets which
have different effects when repeated.

> r +$S05#b8
> w +$g#67
> r <Timeout: 3 seconds>
> w $g#67
> r <Timeout: 3 seconds>
> w $g#67
> r <Timeout: 3 seconds>
> w $g#67
> r <Timeout: 3 seconds><Timeout: 3 seconds>
> w -
> r <Timeout: 3 seconds>
> w -
> r <Timeout: 3 seconds>
> w -+
> 
> infinitely. Because the target side NetBSD kernel throws all
> characters until get a new packet start ('$') char.

What's happened here, the four repetitions of $g#67 were all
completely lost, and then GDB timed out?  IMO, we should treat some of
these timeouts as fatal to the protocol conversation.

-- 
Daniel Jacobowitz
CodeSourcery


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]