All of lore.kernel.org
 help / color / mirror / Atom feed
From: Olaf Hering <olh@suse.de>
To: linux-kernel@vger.kernel.org, Sachin Sant <sachinp@in.ibm.com>
Subject: Re: [RFC] [PATCH] Adding ctrl-o sysrq hack support to 8250 driver
Date: Thu, 8 Dec 2005 15:58:21 +0100	[thread overview]
Message-ID: <20051208145821.GA15169@suse.de> (raw)
In-Reply-To: <20051207233911.GP6793@flint.arm.linux.org.uk>

 On Wed, Dec 07, Russell King wrote:

> Easily.  Have a look at the internals of uart_handle_break() in
> include/linux/serial_core.h

This one works for me, tested with 2.6.5.


 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

  reply	other threads:[~2005-12-08 14:58 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-30 11:17 [RFC] [PATCH] Adding ctrl-o sysrq hack support to 8250 driver Sachin Sant
2005-11-30 12:12 ` Arjan van de Ven
2005-11-30 13:04 ` Russell King
2005-12-06  6:48   ` Sachin Sant
2005-12-06 17:16     ` Russell King
2005-12-07  6:31       ` Sachin Sant
2005-12-07 22:22       ` Olaf Hering
2005-12-07 23:39         ` Russell King
2005-12-08 14:58           ` Olaf Hering [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-12-08  1:38 Milton Miller

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=20051208145821.GA15169@suse.de \
    --to=olh@suse.de \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.