diff options
author | phk <phk@FreeBSD.org> | 1999-05-09 10:51:13 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-05-09 10:51:13 +0000 |
commit | e8f4fc4a1d3555ba5d3ce423b41c82b7fce94a63 (patch) | |
tree | 623bf04dc60f78005b62c8986b81469006615edb /sys/ddb/db_command.c | |
parent | e85d75ef71e87265d72acde0261bcc0bd8b5ad6f (diff) | |
download | FreeBSD-src-e8f4fc4a1d3555ba5d3ce423b41c82b7fce94a63.zip FreeBSD-src-e8f4fc4a1d3555ba5d3ce423b41c82b7fce94a63.tar.gz |
add some amount of sanity to the way the gdb stuff finds its device.
I'm not too happy about the result either, but at least it has less
chance of backfiring.
This particular feature could be called "a mess" without offending
anybody.
Diffstat (limited to 'sys/ddb/db_command.c')
-rw-r--r-- | sys/ddb/db_command.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/ddb/db_command.c b/sys/ddb/db_command.c index f86ad2f..6e0e932 100644 --- a/sys/ddb/db_command.c +++ b/sys/ddb/db_command.c @@ -23,7 +23,7 @@ * any improvements or extensions that they make and grant Carnegie the * rights to redistribute these changes. * - * $Id: db_command.c,v 1.29 1999/01/14 06:22:01 jdp Exp $ + * $Id: db_command.c,v 1.30 1999/05/07 23:08:23 mckusick Exp $ */ /* @@ -39,6 +39,8 @@ #include <sys/reboot.h> #include <sys/systm.h> +#include <machine/cons.h> + #include <ddb/ddb.h> #include <ddb/db_command.h> #include <ddb/db_lex.h> @@ -535,7 +537,9 @@ db_fncall(dummy1, dummy2, dummy3, dummy4) /* Enter GDB remote protocol debugger on the next trap. */ -dev_t gdbdev; +dev_t gdbdev = NODEV; +cn_getc_t *gdb_getc; +cn_putc_t *gdb_putc; static void db_gdb (dummy1, dummy2, dummy3, dummy4) @@ -545,7 +549,7 @@ db_gdb (dummy1, dummy2, dummy3, dummy4) char * dummy4; { - if (gdbdev == -1) { + if (gdbdev == NODEV) { db_printf("No gdb port enabled. Set flag 0x80 on desired port\n"); db_printf("in your configuration file (currently sio only).\n"); return; |