Skip to content

Commit

Permalink
USB: ftdi_sio: use error code from usb stack in read_latency_timer
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Johan Hovold authored and Greg Kroah-Hartman committed Mar 2, 2010
1 parent 551cdbb commit 4357369
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/usb/serial/ftdi_sio.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down

0 comments on commit 4357369

Please sign in to comment.