Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 285680
b: refs/heads/master
c: d0d3435
h: refs/heads/master
v: v3
  • Loading branch information
Hans de Goede authored and Mauro Carvalho Chehab committed Jan 6, 2012
1 parent 4f6ad44 commit bfcb2ec
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 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: 66957b864646e2ea0aebc66d1173f39a63509a19
refs/heads/master: d0d3435b212f88aebee6a06e002e4fd3b487a918
7 changes: 6 additions & 1 deletion trunk/drivers/media/video/gspca/gspca.c
Original file line number Diff line number Diff line change
Expand Up @@ -698,12 +698,17 @@ static int build_isoc_ep_tb(struct gspca_dev *gspca_dev,
USB_ENDPOINT_XFER_ISOC);
if (ep == NULL)
continue;
if (ep->desc.bInterval == 0) {
pr_err("alt %d iso endp with 0 interval\n", j);
continue;
}
psize = le16_to_cpu(ep->desc.wMaxPacketSize);
psize = (psize & 0x07ff) * (1 + ((psize >> 11) & 3));
bandwidth = psize * ep->desc.bInterval * 1000;
bandwidth = psize * 1000;
if (gspca_dev->dev->speed == USB_SPEED_HIGH
|| gspca_dev->dev->speed == USB_SPEED_SUPER)
bandwidth *= 8;
bandwidth /= 1 << (ep->desc.bInterval - 1);
if (bandwidth <= last_bw)
continue;
if (bandwidth < ep_tb->bandwidth) {
Expand Down

0 comments on commit bfcb2ec

Please sign in to comment.