OSDN Git Service

[media] gspca: correct speed testing
authorOliver Neukum <oneukum@suse.com>
Mon, 2 May 2016 11:22:26 +0000 (08:22 -0300)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Fri, 8 Jul 2016 18:04:53 +0000 (15:04 -0300)
Allow for SS+ devices

Signed-off-by: Oliver Neukum <ONeukum@suse.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/usb/gspca/gspca.c

index 84b0d6a..b17bd7e 100644 (file)
@@ -705,7 +705,7 @@ static int build_isoc_ep_tb(struct gspca_dev *gspca_dev,
                        psize = (psize & 0x07ff) * (1 + ((psize >> 11) & 3));
                        bandwidth = psize * 1000;
                        if (gspca_dev->dev->speed == USB_SPEED_HIGH
-                        || gspca_dev->dev->speed == USB_SPEED_SUPER)
+                        || gspca_dev->dev->speed >= USB_SPEED_SUPER)
                                bandwidth *= 8;
                        bandwidth /= 1 << (ep->desc.bInterval - 1);
                        if (bandwidth <= last_bw)