aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorJean-François Moine <moinejf@free.fr>2011-05-17 04:08:59 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-05-21 08:35:43 -0400
commitbd62bbcd31f36db2ffb08a9f32743b2595d12613 (patch)
treec0975563daf61460675101ec712a37b530f981af /drivers/media
parentcf221766f58cf12cbaffccddfa48e906604f8545 (diff)
[media] gspca: Fix some warnings tied to 'no debug'
This patch fixes the warnings raised by unsetting the option GSPCA_DEBUG. Signed-off-by: Jean-François Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/gspca/gl860/gl860.c15
-rw-r--r--drivers/media/video/gspca/spca508.c5
-rw-r--r--drivers/media/video/gspca/zc3xx.c5
3 files changed, 9 insertions, 16 deletions
diff --git a/drivers/media/video/gspca/gl860/gl860.c b/drivers/media/video/gspca/gl860/gl860.c
index 99083038cec3..e8e071aa212f 100644
--- a/drivers/media/video/gspca/gl860/gl860.c
+++ b/drivers/media/video/gspca/gl860/gl860.c
@@ -499,21 +499,8 @@ MODULE_DEVICE_TABLE(usb, device_table);
499static int sd_probe(struct usb_interface *intf, 499static int sd_probe(struct usb_interface *intf,
500 const struct usb_device_id *id) 500 const struct usb_device_id *id)
501{ 501{
502 struct gspca_dev *gspca_dev; 502 return gspca_dev_probe(intf, id,
503 s32 ret;
504
505 ret = gspca_dev_probe(intf, id,
506 &sd_desc_mi1320, sizeof(struct sd), THIS_MODULE); 503 &sd_desc_mi1320, sizeof(struct sd), THIS_MODULE);
507
508 if (ret >= 0) {
509 gspca_dev = usb_get_intfdata(intf);
510
511 PDEBUG(D_PROBE,
512 "Camera is now controlling video device %s",
513 video_device_node_name(&gspca_dev->vdev));
514 }
515
516 return ret;
517} 504}
518 505
519static void sd_disconnect(struct usb_interface *intf) 506static void sd_disconnect(struct usb_interface *intf)
diff --git a/drivers/media/video/gspca/spca508.c b/drivers/media/video/gspca/spca508.c
index 41dce49fb43d..9d0b46027b93 100644
--- a/drivers/media/video/gspca/spca508.c
+++ b/drivers/media/video/gspca/spca508.c
@@ -1375,7 +1375,6 @@ static int sd_config(struct gspca_dev *gspca_dev,
1375{ 1375{
1376 struct sd *sd = (struct sd *) gspca_dev; 1376 struct sd *sd = (struct sd *) gspca_dev;
1377 struct cam *cam; 1377 struct cam *cam;
1378 int data1, data2;
1379 const u16 (*init_data)[2]; 1378 const u16 (*init_data)[2];
1380 static const u16 (*(init_data_tb[]))[2] = { 1379 static const u16 (*(init_data_tb[]))[2] = {
1381 spca508_vista_init_data, /* CreativeVista 0 */ 1380 spca508_vista_init_data, /* CreativeVista 0 */
@@ -1386,6 +1385,9 @@ static int sd_config(struct gspca_dev *gspca_dev,
1386 spca508_init_data, /* ViewQuestVQ110 5 */ 1385 spca508_init_data, /* ViewQuestVQ110 5 */
1387 }; 1386 };
1388 1387
1388#ifdef GSPCA_DEBUG
1389 int data1, data2;
1390
1389 /* Read from global register the USB product and vendor IDs, just to 1391 /* Read from global register the USB product and vendor IDs, just to
1390 * prove that we can communicate with the device. This works, which 1392 * prove that we can communicate with the device. This works, which
1391 * confirms at we are communicating properly and that the device 1393 * confirms at we are communicating properly and that the device
@@ -1400,6 +1402,7 @@ static int sd_config(struct gspca_dev *gspca_dev,
1400 1402
1401 data1 = reg_read(gspca_dev, 0x8621); 1403 data1 = reg_read(gspca_dev, 0x8621);
1402 PDEBUG(D_PROBE, "Window 1 average luminance: %d", data1); 1404 PDEBUG(D_PROBE, "Window 1 average luminance: %d", data1);
1405#endif
1403 1406
1404 cam = &gspca_dev->cam; 1407 cam = &gspca_dev->cam;
1405 cam->cam_mode = sif_mode; 1408 cam->cam_mode = sif_mode;
diff --git a/drivers/media/video/gspca/zc3xx.c b/drivers/media/video/gspca/zc3xx.c
index dfb1f810c831..61cdd56a74a9 100644
--- a/drivers/media/video/gspca/zc3xx.c
+++ b/drivers/media/video/gspca/zc3xx.c
@@ -6266,7 +6266,6 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev)
6266{ 6266{
6267 struct sd *sd = (struct sd *) gspca_dev; 6267 struct sd *sd = (struct sd *) gspca_dev;
6268 int i; 6268 int i;
6269 u8 retbyte;
6270 u16 retword; 6269 u16 retword;
6271 6270
6272/*fixme: lack of 8b=b3 (11,12)-> 10, 8b=e0 (14,15,16)-> 12 found in gspcav1*/ 6271/*fixme: lack of 8b=b3 (11,12)-> 10, 8b=e0 (14,15,16)-> 12 found in gspcav1*/
@@ -6359,8 +6358,12 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev)
6359 retword |= i2c_read(gspca_dev, 0x01); /* ID 1 */ 6358 retword |= i2c_read(gspca_dev, 0x01); /* ID 1 */
6360 PDEBUG(D_PROBE, "probe 3wr vga 2 0x%04x", retword); 6359 PDEBUG(D_PROBE, "probe 3wr vga 2 0x%04x", retword);
6361 if (retword == 0x2030) { 6360 if (retword == 0x2030) {
6361#ifdef GSPCA_DEBUG
6362 u8 retbyte;
6363
6362 retbyte = i2c_read(gspca_dev, 0x02); /* revision number */ 6364 retbyte = i2c_read(gspca_dev, 0x02); /* revision number */
6363 PDEBUG(D_PROBE, "sensor PO2030 rev 0x%02x", retbyte); 6365 PDEBUG(D_PROBE, "sensor PO2030 rev 0x%02x", retbyte);
6366#endif
6364 send_unknown(gspca_dev, SENSOR_PO2030); 6367 send_unknown(gspca_dev, SENSOR_PO2030);
6365 return retword; 6368 return retword;
6366 } 6369 }