Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 113915
b: refs/heads/master
c: 51977a8
h: refs/heads/master
i:
  113913: 52bdaf0
  113911: 2c9e1ee
v: v3
  • Loading branch information
Jean-Francois Moine authored and Mauro Carvalho Chehab committed Oct 12, 2008
1 parent 2e45b99 commit 0941e38
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 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: 7b537391dde35d7f412417a95f02f89af08dd2d3
refs/heads/master: 51977a8daab6775b91986b566056eb2a2f10202d
14 changes: 7 additions & 7 deletions trunk/drivers/media/video/gspca/gspca.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ static void bulk_irq(struct urb *urb
{
struct gspca_dev *gspca_dev = (struct gspca_dev *) urb->context;
struct gspca_frame *frame;
int j, ret;
int j;

PDEBUG(D_PACK, "bulk irq");
if (!gspca_dev->streaming)
Expand All @@ -212,11 +212,6 @@ static void bulk_irq(struct urb *urb
urb->transfer_buffer,
urb->actual_length);
}
/* resubmit the URB */
urb->status = 0;
ret = usb_submit_urb(urb, GFP_ATOMIC);
if (ret < 0)
PDEBUG(D_ERR|D_PACK, "usb_submit_urb() ret %d", ret);
}

/*
Expand Down Expand Up @@ -502,13 +497,14 @@ static int create_urbs(struct gspca_dev *gspca_dev,
PDEBUG(D_STREAM,
"isoc %d pkts size %d = bsize:%d",
npkt, psize, bsize);
nurbs = DEF_NURBS;
} else {
npkt = 0;
bsize = psize;
PDEBUG(D_STREAM, "bulk bsize:%d", bsize);
nurbs = 1;
}

nurbs = DEF_NURBS;
gspca_dev->nurbs = nurbs;
for (n = 0; n < nurbs; n++) {
urb = usb_alloc_urb(npkt, GFP_KERNEL);
Expand Down Expand Up @@ -583,6 +579,10 @@ static int gspca_init_transfer(struct gspca_dev *gspca_dev)
gspca_dev->streaming = 1;
atomic_set(&gspca_dev->nevent, 0);

/* start the bulk transfer is done by the subdriver */
if (gspca_dev->bulk)
break;

/* submit the URBs */
for (n = 0; n < gspca_dev->nurbs; n++) {
ret = usb_submit_urb(gspca_dev->urb[n], GFP_KERNEL);
Expand Down

0 comments on commit 0941e38

Please sign in to comment.