Skip to contentSkip to conversation

gspca: Fix falling back to lower isoc alt

PATCH New Hans de Goede 2 participants 3 messages Dec 31, 2011 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gspca: Fix falling back to lower isoc alt

Hi Mauro et all,

I'm afraid my recent work on gscpa has uncovered another regression in the gspca core. It no longer properly falls back to a lower alt setting if there is not enough bandwidth for the initially choosen one.

This is a problem when usb1 devices are plugged into a usb2 hub, or into a sandybridge motherboard (which uses usb2 hubs internally), since the ehci scheduling code in the kernel does not allow usb1 devices to use full iso bandwidth (long story). So we must fall back to a lower setting there!

This means that many (iso mode) usb1 devices supported by gscpa won't work at their highest resolution with such systems. This patch fixes the falling back to lower alt settings, thereby also fixing these devices no longer working (reproduced and fix tested with several cams).

Therefor I'm suggesting this fix as a last minute regression fix for 3.2 Mauro, please send this patch on its merry way to Linus, thanks!

Regards,

Hans

#1 lore raw

PATCH 1/1 gspca: Fix falling back to lower isoc alt settings

The current gspca core code has a regression where it no longer properly falls back to lower alt settings when there is not enough bandwidth.

This causes many iso based usb-1 cameras to not work when plugged into a usb2 hub or a sandybridge chipset motherboard!

This patch fixes this.

---
 drivers/media/video/gspca/gspca.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/media/video/gspca/gspca.c +1 -1
index 7fb90ae..c27dc09 100644
@@ -988,7 +988,7 @@ retry:
 				ret = -EIO;
 				goto out;
 			}
-			alt = ep_tb[--alt_idx].alt;
+			gspca_dev->alt = ep_tb[--alt_idx].alt;
 		}
 	}
 out:
Signature · 1 line
1.7.7.4
#2 lore raw

PATCH 1/1 gspca: Fix falling back to lower isoc alt settings

The current gspca core code has a regression where it no longer properly falls back to lower alt settings when there is not enough bandwidth.

This causes many iso based usb-1 cameras to not work when plugged into a usb2 hub or a sandybridge chipset motherboard!

This patch fixes this.

---
 drivers/media/video/gspca/gspca.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/media/video/gspca/gspca.c +1 -1
index 7fb90ae..c27dc09 100644
@@ -988,7 +988,7 @@ retry:
 				ret = -EIO;
 				goto out;
 			}
-			alt = ep_tb[--alt_idx].alt;
+			gspca_dev->alt = ep_tb[--alt_idx].alt;
 		}
 	}
 out:
Signature · 6 lines
1.7.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html