tty: Define tty_*() printk macros
Since not all ttys are devices (eg., SysV ptys), dev_*() printk macros cannot be used. Define tty_*() printk macros that output in similar format to dev_*() macros (ie., <driver> <tty>: .....). Transform the most-trivial printk( LEVEL ...) usage to tty_*() usage. NB: The function name has been eliminated from messages with unique context, or prefixed to the format when given. Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:

committad av
Greg Kroah-Hartman

förälder
0a083eddae
incheckning
339f36ba14
@@ -462,14 +462,13 @@ int tty_port_close_start(struct tty_port *port,
|
||||
|
||||
spin_lock_irqsave(&port->lock, flags);
|
||||
if (tty->count == 1 && port->count != 1) {
|
||||
printk(KERN_WARNING
|
||||
"tty_port_close_start: tty->count = 1 port count = %d.\n",
|
||||
port->count);
|
||||
tty_warn(tty, "%s: tty->count = 1 port count = %d\n", __func__,
|
||||
port->count);
|
||||
port->count = 1;
|
||||
}
|
||||
if (--port->count < 0) {
|
||||
printk(KERN_WARNING "tty_port_close_start: count = %d\n",
|
||||
port->count);
|
||||
tty_warn(tty, "%s: bad port count (%d)\n", __func__,
|
||||
port->count);
|
||||
port->count = 0;
|
||||
}
|
||||
|
||||
|
Referens i nytt ärende
Block a user