diff options
Diffstat (limited to 'usr/src/uts/common/io/kb8042/kb8042.c')
-rw-r--r-- | usr/src/uts/common/io/kb8042/kb8042.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/usr/src/uts/common/io/kb8042/kb8042.c b/usr/src/uts/common/io/kb8042/kb8042.c index 560557934d..396d1c9b08 100644 --- a/usr/src/uts/common/io/kb8042/kb8042.c +++ b/usr/src/uts/common/io/kb8042/kb8042.c @@ -23,7 +23,7 @@ /* All Rights Reserved */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -1013,6 +1013,8 @@ kb8042_received_byte( enum keystate state; boolean_t synthetic_release_needed; + static int attempt_one_reset = 1; + #ifdef KD_DEBUG kb8042_debug_hotkey(scancode); #endif @@ -1041,6 +1043,20 @@ kb8042_received_byte( } #endif + /* trigger switch back to text mode */ + if (attempt_one_reset == 1) { + ldi_ident_t li; + extern void progressbar_key_abort(ldi_ident_t); + + if (ldi_ident_from_dev(kb8042->w_dev, &li) != 0) { + cmn_err(CE_NOTE, "!ldi_ident_from_stream failed"); + } else { + progressbar_key_abort(li); + ldi_ident_release(li); + } + attempt_one_reset = 0; + } + /* * Don't know if we want this permanently, but it seems interesting * for the moment. |