diff options
Diffstat (limited to 'drivers/usb/serial/cyberjack.c')
-rw-r--r-- | drivers/usb/serial/cyberjack.c | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/drivers/usb/serial/cyberjack.c b/drivers/usb/serial/cyberjack.c index 068680f9929d..858bdd038fbc 100644 --- a/drivers/usb/serial/cyberjack.c +++ b/drivers/usb/serial/cyberjack.c | |||
@@ -141,7 +141,8 @@ static int cyberjack_startup(struct usb_serial *serial) | |||
141 | result = usb_submit_urb(serial->port[i]->interrupt_in_urb, | 141 | result = usb_submit_urb(serial->port[i]->interrupt_in_urb, |
142 | GFP_KERNEL); | 142 | GFP_KERNEL); |
143 | if (result) | 143 | if (result) |
144 | err(" usb_submit_urb(read int) failed"); | 144 | dev_err(&serial->dev->dev, |
145 | "usb_submit_urb(read int) failed\n"); | ||
145 | dbg("%s - usb_submit_urb(int urb)", __func__); | 146 | dbg("%s - usb_submit_urb(int urb)", __func__); |
146 | } | 147 | } |
147 | 148 | ||
@@ -274,8 +275,9 @@ static int cyberjack_write(struct tty_struct *tty, | |||
274 | /* send the data out the bulk port */ | 275 | /* send the data out the bulk port */ |
275 | result = usb_submit_urb(port->write_urb, GFP_ATOMIC); | 276 | result = usb_submit_urb(port->write_urb, GFP_ATOMIC); |
276 | if (result) { | 277 | if (result) { |
277 | err("%s - failed submitting write urb, error %d", | 278 | dev_err(&port->dev, |
278 | __func__, result); | 279 | "%s - failed submitting write urb, error %d", |
280 | __func__, result); | ||
279 | /* Throw away data. No better idea what to do with it. */ | 281 | /* Throw away data. No better idea what to do with it. */ |
280 | priv->wrfilled = 0; | 282 | priv->wrfilled = 0; |
281 | priv->wrsent = 0; | 283 | priv->wrsent = 0; |
@@ -351,7 +353,9 @@ static void cyberjack_read_int_callback(struct urb *urb) | |||
351 | port->read_urb->dev = port->serial->dev; | 353 | port->read_urb->dev = port->serial->dev; |
352 | result = usb_submit_urb(port->read_urb, GFP_ATOMIC); | 354 | result = usb_submit_urb(port->read_urb, GFP_ATOMIC); |
353 | if (result) | 355 | if (result) |
354 | err("%s - failed resubmitting read urb, error %d", __func__, result); | 356 | dev_err(&port->dev, "%s - failed resubmitting " |
357 | "read urb, error %d\n", | ||
358 | __func__, result); | ||
355 | dbg("%s - usb_submit_urb(read urb)", __func__); | 359 | dbg("%s - usb_submit_urb(read urb)", __func__); |
356 | } | 360 | } |
357 | } | 361 | } |
@@ -360,7 +364,7 @@ resubmit: | |||
360 | port->interrupt_in_urb->dev = port->serial->dev; | 364 | port->interrupt_in_urb->dev = port->serial->dev; |
361 | result = usb_submit_urb(port->interrupt_in_urb, GFP_ATOMIC); | 365 | result = usb_submit_urb(port->interrupt_in_urb, GFP_ATOMIC); |
362 | if (result) | 366 | if (result) |
363 | err(" usb_submit_urb(read int) failed"); | 367 | dev_err(&port->dev, "usb_submit_urb(read int) failed\n"); |
364 | dbg("%s - usb_submit_urb(int urb)", __func__); | 368 | dbg("%s - usb_submit_urb(int urb)", __func__); |
365 | } | 369 | } |
366 | 370 | ||
@@ -414,8 +418,8 @@ static void cyberjack_read_bulk_callback(struct urb *urb) | |||
414 | port->read_urb->dev = port->serial->dev; | 418 | port->read_urb->dev = port->serial->dev; |
415 | result = usb_submit_urb(port->read_urb, GFP_ATOMIC); | 419 | result = usb_submit_urb(port->read_urb, GFP_ATOMIC); |
416 | if (result) | 420 | if (result) |
417 | err("%s - failed resubmitting read urb, error %d", | 421 | dev_err(&port->dev, "%s - failed resubmitting read " |
418 | __func__, result); | 422 | "urb, error %d\n", __func__, result); |
419 | dbg("%s - usb_submit_urb(read urb)", __func__); | 423 | dbg("%s - usb_submit_urb(read urb)", __func__); |
420 | } | 424 | } |
421 | } | 425 | } |
@@ -462,8 +466,9 @@ static void cyberjack_write_bulk_callback(struct urb *urb) | |||
462 | /* send the data out the bulk port */ | 466 | /* send the data out the bulk port */ |
463 | result = usb_submit_urb(port->write_urb, GFP_ATOMIC); | 467 | result = usb_submit_urb(port->write_urb, GFP_ATOMIC); |
464 | if (result) { | 468 | if (result) { |
465 | err("%s - failed submitting write urb, error %d", | 469 | dev_err(&port->dev, |
466 | __func__, result); | 470 | "%s - failed submitting write urb, error %d\n", |
471 | __func__, result); | ||
467 | /* Throw away data. No better idea what to do with it. */ | 472 | /* Throw away data. No better idea what to do with it. */ |
468 | priv->wrfilled = 0; | 473 | priv->wrfilled = 0; |
469 | priv->wrsent = 0; | 474 | priv->wrsent = 0; |