提交 55b2afbb 编写于 作者: J Johan Hovold 提交者: Greg Kroah-Hartman

USB: cp210x: call generic open last in open

Make sure port is fully initialised before calling generic open.
Signed-off-by: NJohan Hovold <jhovold@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 791b7d7c
...@@ -410,13 +410,10 @@ static int cp210x_open(struct tty_struct *tty, struct usb_serial_port *port) ...@@ -410,13 +410,10 @@ static int cp210x_open(struct tty_struct *tty, struct usb_serial_port *port)
return result; return result;
} }
result = usb_serial_generic_open(tty, port);
if (result)
return result;
/* Configure the termios structure */ /* Configure the termios structure */
cp210x_get_termios(tty, port); cp210x_get_termios(tty, port);
return 0;
return usb_serial_generic_open(tty, port);
} }
static void cp210x_close(struct usb_serial_port *port) static void cp210x_close(struct usb_serial_port *port)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册