From: Andy Walls Date: Sun, 12 Sep 2010 17:45:18 +0000 (-0300) Subject: V4L/DVB: gspca_cpia1: Restore QX3 illuminators' state on resume X-Git-Tag: MMI-PSA29.97-13-9~21911^2~432 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c67be3ccd7616ed828586d5d3f4b48b438c0a433;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git V4L/DVB: gspca_cpia1: Restore QX3 illuminators' state on resume Turn the lights of the QX3 on (or off) as needed when resuming and at module load. Signed-off-by: Andy Walls Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/gspca/cpia1.c b/drivers/media/video/gspca/cpia1.c index a9a4074ee682..3dbc7a16889b 100644 --- a/drivers/media/video/gspca/cpia1.c +++ b/drivers/media/video/gspca/cpia1.c @@ -1756,6 +1756,10 @@ static int sd_init(struct gspca_dev *gspca_dev) if (ret) return ret; + /* Ensure the QX3 illuminators' states are restored upon resume */ + if (sd->params.qx3.qx3_detected) + command_setlights(gspca_dev); + sd_stopN(gspca_dev); PDEBUG(D_PROBE, "CPIA Version: %d.%02d (%d.%d)",