The patch number 14390 was added via Douglas Schilling Landgraf
<[email protected]>
to http://linuxtv.org/hg/v4l-dvb master development tree.
Kernel patches in this development tree may be modified to be backward
compatible with older kernels. Compatibility modifications will be
removed before inclusion into the mainstream Kernel
If anyone has any objections, please let us know by sending a message to:
Linux Media Mailing List <[email protected]>
------
From: Hans de Goede <[email protected]>
gspca_ov519: add support for the button on ov511 based cams
Due to hardware limitations this only works while the camera is
streaming.
Priority: normal
Signed-off-by: Hans de Goede <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Douglas Schilling Landgraf <[email protected]>
---
linux/drivers/media/video/gspca/ov519.c | 22 +++++++++++++++++-----
1 file changed, 17 insertions(+), 5 deletions(-)
diff -r 335fb88c2820 -r 34d81dd7d1e6 linux/drivers/media/video/gspca/ov519.c
--- a/linux/drivers/media/video/gspca/ov519.c Thu Mar 04 02:46:58 2010 -0300
+++ b/linux/drivers/media/video/gspca/ov519.c Thu Mar 04 02:48:20 2010 -0300
@@ -2706,6 +2706,11 @@
sd->snapshot_needs_reset = 0;
switch (sd->bridge) {
+ case BRIDGE_OV511:
+ case BRIDGE_OV511PLUS:
+ reg_w(sd, R51x_SYS_SNAP, 0x02);
+ reg_w(sd, R51x_SYS_SNAP, 0x00);
+ break;
case BRIDGE_OV518:
case BRIDGE_OV518PLUS:
reg_w(sd, R51x_SYS_SNAP, 0x02); /* Reset */
@@ -4015,11 +4020,17 @@
sd->snapshot_pressed = state;
} else {
- /* On the ov519 we need to reset the button state multiple
- times, as resetting does not work as long as the button
- stays pressed */
- if (sd->bridge == BRIDGE_OV519 && state)
- sd->snapshot_needs_reset = 1;
+ /* On the ov511 / ov519 we need to reset the button state
+ multiple times, as resetting does not work as long as the
+ button stays pressed */
+ switch (sd->bridge) {
+ case BRIDGE_OV511:
+ case BRIDGE_OV511PLUS:
+ case BRIDGE_OV519:
+ if (state)
+ sd->snapshot_needs_reset = 1;
+ break;
+ }
}
}
@@ -4044,6 +4055,7 @@
*/
if (!(in[0] | in[1] | in[2] | in[3] | in[4] | in[5] | in[6] | in[7]) &&
(in[8] & 0x08)) {
+ ov51x_handle_button(gspca_dev, (in[8] >> 2) & 1);
if (in[8] & 0x80) {
/* Frame end */
if ((in[9] + 1) * 8 != gspca_dev->width ||
---
Patch is available at:
http://linuxtv.org/hg/v4l-dvb/rev/34d81dd7d1e61d46c04bfa4b0586d9209e566df7
_______________________________________________
linuxtv-commits mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits