diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2008-06-08 20:57:20 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2008-06-08 20:57:20 +0000 |
commit | 2c57a9726dcd1d56791188ab7cac0a45ef2dbeae (patch) | |
tree | 0038efe5b66eecfc3617bc5bfe0b109acadc2495 /sys/arch/hp300 | |
parent | a587c12e336de345a9c788100500c94b6fa7c0f4 (diff) |
Make sure to cnpollc(1)/cnpollc(0) around cngetc() or getsn() calls.
Diffstat (limited to 'sys/arch/hp300')
-rw-r--r-- | sys/arch/hp300/hp300/machdep.c | 4 | ||||
-rw-r--r-- | sys/arch/hp300/hp300/trap.c | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/sys/arch/hp300/hp300/machdep.c b/sys/arch/hp300/hp300/machdep.c index 6d269ebe747..bc6226fdcad 100644 --- a/sys/arch/hp300/hp300/machdep.c +++ b/sys/arch/hp300/hp300/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.118 2008/04/09 16:58:10 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.119 2008/06/08 20:57:16 miod Exp $ */ /* $NetBSD: machdep.c,v 1.121 1999/03/26 23:41:29 mycroft Exp $ */ /* @@ -692,7 +692,9 @@ haltsys: /* Finally, halt/reboot the system. */ if (howto & RB_HALT) { printf("System halted. Hit any key to reboot.\n\n"); + cnpollc(1); while (cngetc() == 0); + cnpollc(0); } printf("rebooting...\n"); diff --git a/sys/arch/hp300/hp300/trap.c b/sys/arch/hp300/hp300/trap.c index 9338324224c..e96dda2303f 100644 --- a/sys/arch/hp300/hp300/trap.c +++ b/sys/arch/hp300/hp300/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.52 2007/05/15 13:46:22 martin Exp $ */ +/* $OpenBSD: trap.c,v 1.53 2008/06/08 20:57:16 miod Exp $ */ /* $NetBSD: trap.c,v 1.57 1998/02/16 20:58:31 thorpej Exp $ */ /* @@ -307,7 +307,8 @@ dopanic: printf("trap during panic!\n"); #ifdef DEBUG /* XXX should be a machine-dependent hook */ - printf("(press a key)\n"); (void)cngetc(); + printf("(press a key)\n"); + cnpollc(1); (void)cngetc(); cnpollc(0); #endif } regdump(&(frame.F_t), 128); |