]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
USB: mos7720: fix hardware flow control
authorJohan Hovold <jhovold@gmail.com>
Tue, 4 Jun 2013 16:50:31 +0000 (18:50 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Jun 2013 17:49:13 +0000 (10:49 -0700)
commit a26f009a070e840fadacb91013b2391ba7ab6cc2 upstream.

The register access to enable hardware flow control depends on the
device port number and not the port minor number.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/mos7720.c

index 1cfa2aa666130ac3bce8210fa9ddb482d6ff6b78..09236891ffe5371baf00d626ffc6128939843040 100644 (file)
@@ -1644,7 +1644,7 @@ static void change_port_settings(struct tty_struct *tty,
                mos7720_port->shadowMCR |= (UART_MCR_XONANY);
                /* To set hardware flow control to the specified *
                 * serial port, in SP1/2_CONTROL_REG             */
-               if (port->number)
+               if (port_number)
                        write_mos_reg(serial, dummy, SP_CONTROL_REG, 0x01);
                else
                        write_mos_reg(serial, dummy, SP_CONTROL_REG, 0x02);