USB: ftdi_sio: use error code from usb stack in read_latency_timer
authorJohan Hovold <jhovold@gmail.com>
Thu, 24 Dec 2009 11:42:07 +0000 (12:42 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 2 Mar 2010 22:53:36 +0000 (14:53 -0800)
Use same semantics as for write_latency_timer.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/serial/ftdi_sio.c

index 44c5b7717fe811b74aae691167949a02020fcedb..ec901ed5d93caaf0430406d6355ac7b0b0afb0a4 100644 (file)
@@ -1193,10 +1193,9 @@ static int read_latency_timer(struct usb_serial_port *port)
                             0, priv->interface,
                             (char *) &latency, 1, WDR_TIMEOUT);
 
-       if (rv < 0) {
+       if (rv < 0)
                dev_err(&port->dev, "Unable to read latency timer: %i\n", rv);
-               return -EIO;
-       } else
+       else
                priv->latency = latency;
        return rv;
 }