aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/gspca/sn9c20x.c
diff options
context:
space:
mode:
authorJean-Francois Moine <moinejf@free.fr>2009-12-12 04:58:01 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-15 21:18:49 -0500
commit83955556669f69fccfd332b52e9b1796d60c77bd (patch)
tree29b94e2cb24c5de83523838a7dfaa0fe88cf53b8 /drivers/media/video/gspca/sn9c20x.c
parent37b372e5ebe187037e01885151a0afb546a38520 (diff)
V4L/DVB (13626): gspca - many subdrivers: Fix some warnings.
- gl860.c:332:15: warning: cast to restricted __le16 - gl860.c:333:15: warning: cast to restricted __le16 - gl860-mi1320.c:348:5: warning: symbol 'mi1320_camera_settings' was not declared. Should it be static? - gl860-mi2020.c:772:5: warning: symbol 'mi2020_camera_settings' was not declared. Should it be static? - m5602_ov9650.c:444:7: warning: symbol 'data' shadows an earlier one - m5602_core.c:84:5: warning: symbol 'm5602_wait_for_i2c' was not declared. Should it be static? - m5602_core.c:391:6: warning: symbol 'm5602_disconnect' was not declared. Should it be static? - m5602_s5k4aa.c:530:23: warning: dubious: x | !y - m5602_s5k4aa.c:575:23: warning: dubious: x | !y - gspca.c:1196:13: warning: potentially expensive pointer subtraction - mr97310a.c:70:5: warning: symbol 'force_sensor_type' was not declared. Should it be static? - ov519.c:2025:4: warning: do-while statement is not a compound statement - ov519.c:2063:4: warning: do-while statement is not a compound statement - ov519.c:2089:4: warning: do-while statement is not a compound statement - ov519.c:1985:34: warning: incorrect type in assignment (different base types) - sn9c20x.c:1164:5: warning: symbol 'i2c_r1' was not declared. Should it be static? - sn9c20x.c:1189:5: warning: symbol 'i2c_r2' was not declared. Should it be static? - sn9c20x.c:2237:27: warning: right shift by bigger than source value - sn9c20x.c:2237:27: warning: right shift by bigger than source value Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/gspca/sn9c20x.c')
-rw-r--r--drivers/media/video/gspca/sn9c20x.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/media/video/gspca/sn9c20x.c b/drivers/media/video/gspca/sn9c20x.c
index a3d8f4675c0..4cff8035614 100644
--- a/drivers/media/video/gspca/sn9c20x.c
+++ b/drivers/media/video/gspca/sn9c20x.c
@@ -1158,7 +1158,7 @@ static int i2c_w2(struct gspca_dev *gspca_dev, u8 reg, u16 val)
1158 return i2c_w(gspca_dev, row); 1158 return i2c_w(gspca_dev, row);
1159} 1159}
1160 1160
1161int i2c_r1(struct gspca_dev *gspca_dev, u8 reg, u8 *val) 1161static int i2c_r1(struct gspca_dev *gspca_dev, u8 reg, u8 *val)
1162{ 1162{
1163 struct sd *sd = (struct sd *) gspca_dev; 1163 struct sd *sd = (struct sd *) gspca_dev;
1164 u8 row[8]; 1164 u8 row[8];
@@ -1183,7 +1183,7 @@ int i2c_r1(struct gspca_dev *gspca_dev, u8 reg, u8 *val)
1183 return 0; 1183 return 0;
1184} 1184}
1185 1185
1186int i2c_r2(struct gspca_dev *gspca_dev, u8 reg, u16 *val) 1186static int i2c_r2(struct gspca_dev *gspca_dev, u8 reg, u16 *val)
1187{ 1187{
1188 struct sd *sd = (struct sd *) gspca_dev; 1188 struct sd *sd = (struct sd *) gspca_dev;
1189 u8 row[8]; 1189 u8 row[8];
@@ -2175,8 +2175,7 @@ static void configure_sensor_output(struct gspca_dev *gspca_dev, int mode)
2175} 2175}
2176 2176
2177#define HW_WIN(mode, hstart, vstart) \ 2177#define HW_WIN(mode, hstart, vstart) \
2178((const u8 []){hstart & 0xff, hstart >> 8, \ 2178((const u8 []){hstart, 0, vstart, 0, \
2179vstart & 0xff, vstart >> 8, \
2180(mode & MODE_SXGA ? 1280 >> 4 : 640 >> 4), \ 2179(mode & MODE_SXGA ? 1280 >> 4 : 640 >> 4), \
2181(mode & MODE_SXGA ? 1024 >> 3 : 480 >> 3)}) 2180(mode & MODE_SXGA ? 1024 >> 3 : 480 >> 3)})
2182 2181