#include <oskit/gdb_serial.h>void gdb_serial_puts(const char *s);
If a remote debugging connection is currently active, this function sends the specified string, followed by a newline character, to the remote debugger in a special ``output'' (`O') message which causes the line to be sent to the debugger's standard output. This allows the serial line used for remote debugging to double as a remote serial console, as described in Section 10.18.1.If this function is called while no remote debugging connection is active, but the gdb_serial_send and gdb_serial_receive pointers are initialized to point to serial-line communication functions, then this function simply sends the specified line out the serial port using gdb_serial_send. This way, if the kernel attempts to print any messages before a connection has been established or after the connection has been dropped (e.g., by calling gdb_serial_exit), they won't confuse the debugger or cause the kernel to hang as they otherwise would, and they may be seen by the remote user if the serial port is being monitored at the time.
If the gdb_serial_send and gdb_serial_receive pointers are uninitialized (still NULL) when this function is called, it does nothing.
- s
- The string to send to the remote debugger's console. A newline is automatically appended to this string.
- gdb_serial_send
- 10.18.8
- gdb_serial_recv
- 10.18.7