Skip to content

Commit

Permalink
[media] tm6000: bugfix at bulk transfer
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Ringel <linuxtv@stefanringel.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Stefan Ringel authored and Mauro Carvalho Chehab committed Nov 28, 2011
1 parent 8159c18 commit de2a20b
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions drivers/media/video/tm6000/tm6000-dvb.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,19 @@ static void tm6000_urb_received(struct urb *urb)
int ret;
struct tm6000_core *dev = urb->context;

if (urb->status != 0)
switch (urb->status) {
case 0:
case -ETIMEDOUT:
break;
case -ENOENT:
case -ECONNRESET:
case -ESHUTDOWN:
return;
default:
print_err_status(dev, 0, urb->status);
else if (urb->actual_length > 0)
}

if (urb->actual_length > 0)
dvb_dmx_swfilter(&dev->dvb->demux, urb->transfer_buffer,
urb->actual_length);

Expand Down Expand Up @@ -151,7 +161,7 @@ static int tm6000_start_stream(struct tm6000_core *dev)
printk(KERN_ERR "tm6000: pipe resetted\n");

/* mutex_lock(&tm6000_driver.open_close_mutex); */
ret = usb_submit_urb(dvb->bulk_urb, GFP_KERNEL);
ret = usb_submit_urb(dvb->bulk_urb, GFP_ATOMIC);

/* mutex_unlock(&tm6000_driver.open_close_mutex); */
if (ret) {
Expand Down

0 comments on commit de2a20b

Please sign in to comment.