]> git.karo-electronics.de Git - linux-beck.git/commit
USB: serial: opticon: fix CTS retrieval at open
authorJohan Hovold <johan@kernel.org>
Fri, 13 Jan 2017 12:21:08 +0000 (13:21 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 26 Feb 2017 10:10:52 +0000 (11:10 +0100)
commita2ce74e35d5fd1afb5304b645c3b459c922a2c4a
treecbfe8c7da73411675edeec01f180d68885e4576f
parenta1fc6fb5f31edc1b6fb8de092f6ab6fbe967aaa7
USB: serial: opticon: fix CTS retrieval at open

commit 2eee05020a0e7ee7c04422cbacdb07859e45dce6 upstream.

The opticon driver used a control request at open to trigger a CTS
status notification to be sent over the bulk-in pipe. When the driver
was converted to using the generic read implementation, an inverted test
prevented this request from being sent, something which could lead to
TIOCMGET reporting an incorrect CTS state.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Fixes: 7a6ee2b02751 ("USB: opticon: switch to generic read implementation")
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/opticon.c