diff options
author | Arnd Bergmann <arnd@arndb.de> | 2010-06-01 16:53:11 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-08-10 16:47:44 -0400 |
commit | a0821df6e57c8af0053963d0d08c8d5198ea077d (patch) | |
tree | 05086ccd247a7c27320c31093cbc5df66e8b86a2 /drivers/serial | |
parent | e142a31da34b42458e10026b554e66127739cf23 (diff) |
8250: fix set_ldisc operation
The ldisc number now gets passed into ->set_ldisc.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/serial')
-rw-r--r-- | drivers/serial/8250.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c index bc8ed4be9073..355148dc085e 100644 --- a/drivers/serial/8250.c +++ b/drivers/serial/8250.c | |||
@@ -2404,14 +2404,9 @@ serial8250_set_termios(struct uart_port *port, struct ktermios *termios, | |||
2404 | } | 2404 | } |
2405 | 2405 | ||
2406 | static void | 2406 | static void |
2407 | serial8250_set_ldisc(struct uart_port *port) | 2407 | serial8250_set_ldisc(struct uart_port *port, int new) |
2408 | { | 2408 | { |
2409 | int line = port->line; | 2409 | if (new == N_PPS) { |
2410 | |||
2411 | if (line >= port->state->port.tty->driver->num) | ||
2412 | return; | ||
2413 | |||
2414 | if (port->state->port.tty->ldisc->ops->num == N_PPS) { | ||
2415 | port->flags |= UPF_HARDPPS_CD; | 2410 | port->flags |= UPF_HARDPPS_CD; |
2416 | serial8250_enable_ms(port); | 2411 | serial8250_enable_ms(port); |
2417 | } else | 2412 | } else |