On Tue, 2006-08-29 at 09:32 +1000, Tony Breeds wrote:
> On Mon, Aug 28, 2006 at 09:38:08AM -0500, Hollis Blanchard wrote:
> > You probably want to avoid serial_puts() if GDB is attached, no?
> > Otherwise, you'll be sending "garbage" (i.e. non-packet data) down
> > serial line to GDB.
> > Rather than including gdbstub.h here, you might do something like
> > if (in_debugger())
> > debug_puts(sercon_handle, str);
> > else
> > serial_puts(sercon_handle, str);
> but in_debugger() and debug_puts() need to come from somewhere and
> gdbstub.h makes sense or am I missing the point?
a) make it generic (i.e. not called GDB)
b) abstract it into a function, so it can be magically compiled out
(#define in_debugger() 0)
IBM Linux Technology Center
Xen-ppc-devel mailing list