Add a nasty hack to get remote kernel gdb working from ddb. ddb would

complain before that a suitable gdb port had not been setup because gdbdev
was NULL.  This abuses the fact that the gdb port is hard-coded to the
address normally assigned to sio1 and thus hard-codes in sio1 as the gdb
port.  Yuck.
This commit is contained in:
John Baldwin 2000-09-11 04:33:36 +00:00
parent b162b45509
commit a0e1678488
2 changed files with 18 additions and 0 deletions

View File

@ -3240,10 +3240,19 @@ siogdbattach(port, speed)
int s;
u_char cfcr;
struct siocnstate sp;
int unit = 1; /* XXX !!! */
siogdbiobase = port;
gdbdefaultrate = speed;
printf("sio%d: gdb debugging port\n", unit);
siogdbunit = unit;
#if DDB > 0
gdbdev = makedev(CDEV_MAJOR, unit);
gdb_getc = siocngetc;
gdb_putc = siocnputc;
#endif
s = spltty();
/*

View File

@ -3240,10 +3240,19 @@ siogdbattach(port, speed)
int s;
u_char cfcr;
struct siocnstate sp;
int unit = 1; /* XXX !!! */
siogdbiobase = port;
gdbdefaultrate = speed;
printf("sio%d: gdb debugging port\n", unit);
siogdbunit = unit;
#if DDB > 0
gdbdev = makedev(CDEV_MAJOR, unit);
gdb_getc = siocngetc;
gdb_putc = siocnputc;
#endif
s = spltty();
/*