From: Arnd Bergmann Date: Tue, 1 Jun 2010 20:53:11 +0000 (+0200) Subject: 8250: fix set_ldisc operation X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=a0821df6e57c8af0053963d0d08c8d5198ea077d;p=linux-beck.git 8250: fix set_ldisc operation The ldisc number now gets passed into ->set_ldisc. Signed-off-by: Arnd Bergmann Cc: Alan Cox Signed-off-by: Greg Kroah-Hartman --- 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, } static void -serial8250_set_ldisc(struct uart_port *port) +serial8250_set_ldisc(struct uart_port *port, int new) { - int line = port->line; - - if (line >= port->state->port.tty->driver->num) - return; - - if (port->state->port.tty->ldisc->ops->num == N_PPS) { + if (new == N_PPS) { port->flags |= UPF_HARDPPS_CD; serial8250_enable_ms(port); } else