public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Brian Beattie <brianb@apcon.com>
To: linux-kernel@vger.kernel.org
Subject: A question about break and sysrq on a serial console (2.6.19.1)
Date: Wed, 17 Jan 2007 15:56:54 -0800	[thread overview]
Message-ID: <1169078214.16802.17.camel@brianb> (raw)

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


             reply	other threads:[~2007-01-17 23:56 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-17 23:56 Brian Beattie [this message]
2007-01-18  9:13 ` A question about break and sysrq on a serial console (2.6.19.1) 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

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=1169078214.16802.17.camel@brianb \
    --to=brianb@apcon.com \
    --cc=linux-kernel@vger.kernel.org \
    /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