Skip to content

Commit

Permalink
[media] em28xx-audio: provide an error code when URB submit fails
Browse files Browse the repository at this point in the history
Instead of just saying:
	[ 1646.412419] em2882/3 #0: submit of audio urb failed
Print the reason why it failed, to help debugging and fixing it.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
  • Loading branch information
Mauro Carvalho Chehab committed Jan 14, 2014
1 parent 0191a2a commit bf6e8aa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/media/usb/em28xx/em28xx-audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,9 @@ static void em28xx_audio_isocirq(struct urb *urb)
urb->status = 0;

status = usb_submit_urb(urb, GFP_ATOMIC);
if (status < 0) {
if (status < 0)
em28xx_errdev("resubmit of audio urb failed (error=%i)\n",
status);
}
return;
}

Expand All @@ -183,7 +182,8 @@ static int em28xx_init_audio_isoc(struct em28xx *dev)

errCode = usb_submit_urb(dev->adev.urb[i], GFP_ATOMIC);
if (errCode) {
em28xx_errdev("submit of audio urb failed\n");
em28xx_errdev("submit of audio urb failed (error=%i)\n",
errCode);
em28xx_deinit_isoc_audio(dev);
atomic_set(&dev->stream_started, 0);
return errCode;
Expand Down

0 comments on commit bf6e8aa

Please sign in to comment.