Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 167294
b: refs/heads/master
c: e63e278
h: refs/heads/master
v: v3
  • Loading branch information
Johan Hovold authored and Greg Kroah-Hartman committed Oct 9, 2009
1 parent 8e36a35 commit 35f1a65
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 28 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 63b0061246b54b849da8f189ae048e8110d8ce7d
refs/heads/master: e63e278b4d2d867893962d3c7cd13a3a24ceb3f1
28 changes: 1 addition & 27 deletions trunk/drivers/usb/serial/ftdi_sio.c
Original file line number Diff line number Diff line change
Expand Up @@ -2008,49 +2008,23 @@ static int ftdi_chars_in_buffer(struct tty_struct *tty)
static void ftdi_read_bulk_callback(struct urb *urb)
{
struct usb_serial_port *port = urb->context;
struct tty_struct *tty;
struct ftdi_private *priv;
int status = urb->status;

if (urb->number_of_packets > 0) {
dev_err(&port->dev, "%s transfer_buffer_length %d "
"actual_length %d number of packets %d\n", __func__,
urb->transfer_buffer_length,
urb->actual_length, urb->number_of_packets);
dev_err(&port->dev, "%s transfer_flags %x\n", __func__,
urb->transfer_flags);
}

dbg("%s - port %d", __func__, port->number);

if (port->port.count <= 0)
return;

tty = tty_port_tty_get(&port->port);
if (!tty) {
dbg("%s - bad tty pointer - exiting", __func__);
return;
}

priv = usb_get_serial_port_data(port);
if (!priv) {
dbg("%s - bad port private data pointer - exiting", __func__);
goto out;
}

if (urb != port->read_urb)
dev_err(&port->dev, "%s - Not my urb!\n", __func__);

if (status) {
/* This will happen at close every time so it is a dbg not an
err */
dbg("(this is ok on close) nonzero read bulk status received: %d", status);
goto out;
}

priv = usb_get_serial_port_data(port);
ftdi_process_read(&priv->rx_work.work);
out:
tty_kref_put(tty);
} /* ftdi_read_bulk_callback */


Expand Down

0 comments on commit 35f1a65

Please sign in to comment.