diff mbox

[RFC,media] gspca-ov534: don't call sd_start() from sd_init()

Message ID 1375654827-14270-1-git-send-email-ospite@studenti.unina.it (mailing list archive)
State New, archived
Headers show

Commit Message

Antonio Ospite Aug. 4, 2013, 10:20 p.m. UTC
---

Hi Yaroslav,

the patch below should fix the Oops caused by sd_start() called too early, but
I am not sure about why sd_start() was called from sd_init() for Hercules
webcams in the first place, maybe the snippet marked with:

  /* (from ms-win trace) */

in sd_start() must be moved to sd_init() too.

Let me know if the change below alone is enough and the webcam keeps working,
a test with suspend and resume would good to have too.

Thanks,
   Antonio

 drivers/media/usb/gspca/ov534.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Yaroslav Zakharuk Aug. 10, 2013, 6:10 a.m. UTC | #1
Hi Antonio,
> Let me know if the change below alone is enough and the webcam keeps working,
> a test with suspend and resume would good to have too.
I've tested your patch with the latest kernel (3.11.0-rc4) - the webcam 
works OK.  After suspend and resume, the webcam works OK too.
diff mbox

Patch

diff --git a/drivers/media/usb/gspca/ov534.c b/drivers/media/usb/gspca/ov534.c
index 2e28c81..03a33c4 100644
--- a/drivers/media/usb/gspca/ov534.c
+++ b/drivers/media/usb/gspca/ov534.c
@@ -1305,8 +1305,7 @@  static int sd_init(struct gspca_dev *gspca_dev)
 	ov534_set_led(gspca_dev, 1);
 	sccb_w_array(gspca_dev, sensor_init[sd->sensor].val,
 			sensor_init[sd->sensor].len);
-	if (sd->sensor == SENSOR_OV767x)
-		sd_start(gspca_dev);
+
 	sd_stopN(gspca_dev);
 /*	set_frame_rate(gspca_dev);	*/