From: Olaf Hering <olh@suse.de>
To: Andrew Morton <akpm@osdl.org>,
linux-kernel@vger.kernel.org, Sachin Sant <sachinp@in.ibm.com>
Subject: [PATCH] Adding ctrl-o sysrq hack support to 8250 driver
Date: Fri, 9 Dec 2005 15:05:59 +0100 [thread overview]
Message-ID: <20051209140559.GA23868@suse.de> (raw)
If you can queue this up in -mm for a decade or two, just to make sure
it doesnt make some setup unhappy.
a POWER4 system in 'full-system-partition' mode has the console device
on ttyS0. But the user interface to the Linux system console may still
be on the hardware management console (HMC). If this is the case, there
is no way to send a break to trigger a sysrq.
Other setups do already use 'ctrl o' to trigger sysrq. This includes iSeries
virtual console on tty1, and pSeries LPAR console on hvc0 or hvsi0.
'ctrl o' is currently mapped to 'flush output', see 'stty -a'
Signed-off-by: Olaf Hering <olh@suse.de>
drivers/serial/8250.c | 7 +++++++
1 files changed, 7 insertions(+)
Index: linux-2.6.15-rc5-olh/drivers/serial/8250.c
===================================================================
--- linux-2.6.15-rc5-olh.orig/drivers/serial/8250.c
+++ linux-2.6.15-rc5-olh/drivers/serial/8250.c
@@ -1154,6 +1154,13 @@ receive_chars(struct uart_8250_port *up,
*/
}
ch = serial_inp(up, UART_RX);
+
+#if defined(CONFIG_MAGIC_SYSRQ) && defined(CONFIG_SERIAL_CORE_CONSOLE)
+ /* Handle the SysRq ^O Hack, but only on the system console */
+ if (ch == '\x0f' && uart_handle_break(&up->port))
+ goto ignore_char;
+#endif
+
flag = TTY_NORMAL;
up->port.icount.rx++;
--
short story of a lazy sysadmin:
alias appserv=wotan
next reply other threads:[~2005-12-09 14:06 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-09 14:05 Olaf Hering [this message]
2005-12-09 14:10 ` [PATCH] Adding ctrl-o sysrq hack support to 8250 driver Russell King
2005-12-09 15:13 ` Daniel Jacobowitz
2005-12-09 15:19 ` Olaf Hering
2005-12-09 15:26 ` Daniel Jacobowitz
2005-12-09 15:28 ` Olaf Hering
2005-12-09 15:25 ` Erik Mouw
2005-12-09 15:34 ` Olaf Hering
2005-12-09 20:47 ` Olaf Hering
2005-12-09 17:08 ` Russell King
2005-12-12 10:03 ` Olaf Hering
2006-01-03 12:44 ` Olaf Hering
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20051209140559.GA23868@suse.de \
--to=olh@suse.de \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sachinp@in.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox