public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* A question about break and sysrq on a serial console (2.6.19.1)
@ 2007-01-17 23:56 Brian Beattie
  2007-01-18  9:13 ` Russell King
  0 siblings, 1 reply; 4+ messages in thread
From: Brian Beattie @ 2007-01-17 23:56 UTC (permalink / raw)
  To: linux-kernel

I'm trying to do a SYSRQ over a serial console.  As I understand it a
break will do that, but I'm not seeing the SYSRQ.  In looking at
uart_handle_break() in drivers/serial/8250.c it looks like the code will
toggle port->sysrq, rather than just setting it when the port is a
console.  I think the correct code would be to move the "port->sysrq =
0;" to follow the closing brace on the next line, or am I missing
something.

--------------
/*
 * We do the SysRQ and SAK checking like this...
 */
static inline int uart_handle_break(struct uart_port *port)
{
    struct uart_info *info = port->info;
#ifdef SUPPORT_SYSRQ
    if (port->cons && port->cons->index == port->line) {
        if (!port->sysrq) {
            port->sysrq = jiffies + HZ*5;
            return 1;
        }
        port->sysrq = 0;
    }
#endif
    if (port->flags & UPF_SAK)
        do_SAK(info->tty);
    return 0;
}
-------------

It seem to me that this code will toggle port->sysrq.
-- 
Brian Beattie
Firmware Engineer
APCON, Inc.
BrianB@apcon.com


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-01-18 17:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-17 23:56 A question about break and sysrq on a serial console (2.6.19.1) Brian Beattie
2007-01-18  9:13 ` Russell King
     [not found]   ` <1169137187.16802.26.camel@brianb>
     [not found]     ` <20070118164747.GD31418@flint.arm.linux.org.uk>
2007-01-18 16:52       ` Brian Beattie
2007-01-18 17:11         ` Russell King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox