From 8f763cc5d1872ca6139a91bb7d32dd04c1a70a5c Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Sun, 28 Dec 2008 18:09:21 +0100 Subject: gspca - m5602-s5k83a: Add led support to the s5k83a sensor. From: Lukas Karas This patch toggles the led seen on many laptops having a m5602 connected to a Samsung s5k83a sensor. Priority: normal Signed-off-by: Lukas Karas Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 261623f0d..8eed4cc0b 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -61,6 +61,9 @@ struct m5602_sensor { /* Executed when the camera starts to send data */ int (*start)(struct sd *sd); + /* Executed when the camera ends to send data */ + int (*stop)(struct sd *sd); + /* Performs a power down sequence */ int (*power_down)(struct sd *sd); -- cgit v1.2.3 From f432c786231aa49d870920164745f6398096dc60 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 30 Dec 2008 19:27:17 +0100 Subject: gspca - m5602: Rework v4l ctrl handling in all sensors From: Erik Andr?n Previously, all sensors allocated a part of a large ctrl vector. Define this vector separately for each sensor instead. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 8eed4cc0b..5867ee258 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -24,8 +24,6 @@ #define M5602_DEFAULT_FRAME_WIDTH 640 #define M5602_DEFAULT_FRAME_HEIGHT 480 -#define M5602_MAX_CTRLS (V4L2_CID_LASTP1 - V4L2_CID_BASE + 10) - /* Enumerates all supported sensors */ enum sensors { OV9650_SENSOR = 1, @@ -67,8 +65,7 @@ struct m5602_sensor { /* Performs a power down sequence */ int (*power_down)(struct sd *sd); - int nctrls; - struct ctrl ctrls[M5602_MAX_CTRLS]; + const struct ctrl *ctrls; char nmodes; struct v4l2_pix_format modes[]; -- cgit v1.2.3 From 63e01b8a8e4578a822d040b6acb59fabd531b9b6 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 30 Dec 2008 20:48:42 +0100 Subject: gspca - m5602-mt9m111: Separate mode vectors per sensor. From: Erik Andr?n By separating the supported for each sensor into a separate vector we can eliminate the nmodes variable and instead calculate it at runtime. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 5867ee258..3fd92d370 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -66,9 +66,6 @@ struct m5602_sensor { int (*power_down)(struct sd *sd); const struct ctrl *ctrls; - - char nmodes; - struct v4l2_pix_format modes[]; }; #endif -- cgit v1.2.3 From 5ad53f606d69a980600f067aac469e09dec84f70 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 30 Dec 2008 21:06:55 +0100 Subject: gspca - m5602-mt9m111: Move v4l2 controls to main sensor file. From: Erik Andr?n Move over the v4l2 controls to the sensor specific source file. Remove the now redundant sensor struct member. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 3fd92d370..b3e82af65 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -64,8 +64,6 @@ struct m5602_sensor { /* Performs a power down sequence */ int (*power_down)(struct sd *sd); - - const struct ctrl *ctrls; }; #endif -- cgit v1.2.3 From 9cc29332cc27df953ca82fd174a1a6c31dcbe67a Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 30 Dec 2008 21:18:23 +0100 Subject: gspca - m5602: Remove an unused member in the sd struct. From: Erik Andr?n Remove an unused sd struct member. Remove a redundant define while we're at it. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index b3e82af65..5c8fb7aba 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -21,9 +21,6 @@ #include "m5602_bridge.h" -#define M5602_DEFAULT_FRAME_WIDTH 640 -#define M5602_DEFAULT_FRAME_HEIGHT 480 - /* Enumerates all supported sensors */ enum sensors { OV9650_SENSOR = 1, -- cgit v1.2.3 From b91431d4d5b8bc688f4bbf37bfd838fb0a050e93 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Sat, 3 Jan 2009 16:10:11 +0100 Subject: gspca - m5602-ov9650: Add a disconnect hook, setup a ctrl cache ctrl. From: Erik Andr?n Reading and writing to a register doesn't always work reliably. Add a cache and ensure that it is deallocated properly upon module disconnect. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 5c8fb7aba..0d3026936 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -59,6 +59,9 @@ struct m5602_sensor { /* Executed when the camera ends to send data */ int (*stop)(struct sd *sd); + /* Executed when the device is disconnected */ + void (*disconnect)(struct sd *sd); + /* Performs a power down sequence */ int (*power_down)(struct sd *sd); }; -- cgit v1.2.3 From 7c02d8dbb5d410ca9cc0af821a6d24a7f6412d86 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 6 Jan 2009 15:59:42 +0100 Subject: gspca - m5602-mt9m111: Remove the unused power_down struct member From: Erik Andr?n The power_down sensor struct member is almost has no purpose in the current driver abstraction. Remove it. Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 0d3026936..987dcb23e 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -61,9 +61,6 @@ struct m5602_sensor { /* Executed when the device is disconnected */ void (*disconnect)(struct sd *sd); - - /* Performs a power down sequence */ - int (*power_down)(struct sd *sd); }; #endif -- cgit v1.2.3 From 184dc138ba7f6b20c15c20f122015620da869e9e Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 13 Jan 2009 17:55:52 +0100 Subject: gspca - m5602-po1030: Add private green balance control From: Erik Andr?n Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 987dcb23e..5b76b6b62 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -21,6 +21,8 @@ #include "m5602_bridge.h" +#define M5602_V4L2_CID_GREEN_BALANCE (V4L2_CID_PRIVATE_BASE + 0) + /* Enumerates all supported sensors */ enum sensors { OV9650_SENSOR = 1, -- cgit v1.2.3 From 81dcc91ec72ff9b0b3464d46ab0965f53e4499e7 Mon Sep 17 00:00:00 2001 From: Erik Andr?n Date: Tue, 13 Jan 2009 20:40:28 +0100 Subject: gspca - m5602-s5k4aa: Add noise suppression ctrl From: Erik Andr?n Priority: normal Signed-off-by: Erik Andr?n --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 1 + 1 file changed, 1 insertion(+) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index 5b76b6b62..c3a72117b 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -22,6 +22,7 @@ #include "m5602_bridge.h" #define M5602_V4L2_CID_GREEN_BALANCE (V4L2_CID_PRIVATE_BASE + 0) +#define M5602_V4L2_CID_NOISE_SUPPRESION (V4L2_CID_PRIVATE_BASE + 1) /* Enumerates all supported sensors */ enum sensors { -- cgit v1.2.3 From 3996f1d906f6c60eda80447cc1d24e13230c2e27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erik=20Andr=C3=A9n?= Date: Wed, 21 Jan 2009 17:39:17 +0100 Subject: gspca - m5602-ov7660: Design probe function MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Erik Andrén Priority: normal Signed-off-by: Erik Andrén --- linux/drivers/media/video/gspca/m5602/m5602_sensor.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'linux/drivers/media/video/gspca/m5602/m5602_sensor.h') diff --git a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h index c3a72117b..edff4f1f5 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_sensor.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_sensor.h @@ -30,7 +30,8 @@ enum sensors { S5K83A_SENSOR = 2, S5K4AA_SENSOR = 3, MT9M111_SENSOR = 4, - PO1030_SENSOR = 5 + PO1030_SENSOR = 5, + OV7660_SENSOR = 6, }; /* Enumerates all possible instruction types */ -- cgit v1.2.3