diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-07 20:22:04 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-07 20:22:04 -0500 |
commit | 97c440ba41d4e7cddb8e14c7c7ec49dad2560709 (patch) | |
tree | 8fc62e3c3a17d22613d0d6d2a4ecebc8fd19edee /drivers | |
parent | 713404d6082fee34a829a0c6d511e4aec72d7654 (diff) | |
parent | 661263b55d56365af911049f8824d3bf1a7aea85 (diff) |
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6:
V4L/DVB (10191a): Update MAINTAINERS entries on media drivers
V4L/DVB (10190): cx88: Fix some Kbuild troubles
V4L/DVB (10189): dm1105: Fix build with INPUT=m and DVB_DM1105=y
V4L/DVB (10185): Use negated usb_endpoint_xfer_control, etc
V4L/DVB (10182): tda8290: fix TDA8290 + TDA18271 initialization
V4L/DVB (10181): v4l2-device: Fix some sparse warnings
V4L/DVB (10180): drivers/media: Fix a number of sparse warnings
V4L/DVB (10179): tda8290: Fix two sparse warnings
V4L/DVB (10178): dvb_frontend: Fix some sparse warnings due to static symbols
V4L/DVB (10177): Fix sparse warnings on em28xx
V4L/DVB (10176b): pxa-camera: fix redefinition warnings and missing DMA definitions
V4L/DVB (10176a): Switch remaining clear_user_page users over to clear_user_highpage
Diffstat (limited to 'drivers')
27 files changed, 106 insertions, 184 deletions
diff --git a/drivers/media/common/tuners/tda8290.c b/drivers/media/common/tuners/tda8290.c index 0ee79fd7c7a9..4b8662edb7cb 100644 --- a/drivers/media/common/tuners/tda8290.c +++ b/drivers/media/common/tuners/tda8290.c | |||
@@ -150,7 +150,7 @@ static void set_audio(struct dvb_frontend *fe, | |||
150 | } | 150 | } |
151 | } | 151 | } |
152 | 152 | ||
153 | struct { | 153 | static struct { |
154 | unsigned char seq[2]; | 154 | unsigned char seq[2]; |
155 | } fm_mode[] = { | 155 | } fm_mode[] = { |
156 | { { 0x01, 0x81} }, /* Put device into expert mode */ | 156 | { { 0x01, 0x81} }, /* Put device into expert mode */ |
@@ -207,7 +207,6 @@ static void tda8290_set_params(struct dvb_frontend *fe, | |||
207 | msleep(1); | 207 | msleep(1); |
208 | 208 | ||
209 | if (params->mode == V4L2_TUNER_RADIO) { | 209 | if (params->mode == V4L2_TUNER_RADIO) { |
210 | int i; | ||
211 | unsigned char deemphasis[] = { 0x13, 1 }; | 210 | unsigned char deemphasis[] = { 0x13, 1 }; |
212 | 211 | ||
213 | /* FIXME: allow using a different deemphasis */ | 212 | /* FIXME: allow using a different deemphasis */ |
@@ -767,7 +766,8 @@ struct dvb_frontend *tda829x_attach(struct dvb_frontend *fe, | |||
767 | fe->ops.analog_ops.info.name = name; | 766 | fe->ops.analog_ops.info.name = name; |
768 | 767 | ||
769 | if (priv->ver & TDA8290) { | 768 | if (priv->ver & TDA8290) { |
770 | tda8290_init_tuner(fe); | 769 | if (priv->ver & (TDA8275 | TDA8275A)) |
770 | tda8290_init_tuner(fe); | ||
771 | tda8290_init_if(fe); | 771 | tda8290_init_if(fe); |
772 | } else if (priv->ver & TDA8295) | 772 | } else if (priv->ver & TDA8295) |
773 | tda8295_init_if(fe); | 773 | tda8295_init_if(fe); |
diff --git a/drivers/media/dvb/dm1105/Kconfig b/drivers/media/dvb/dm1105/Kconfig index 1332301ef3ae..43f4d44edca6 100644 --- a/drivers/media/dvb/dm1105/Kconfig +++ b/drivers/media/dvb/dm1105/Kconfig | |||
@@ -1,6 +1,7 @@ | |||
1 | config DVB_DM1105 | 1 | config DVB_DM1105 |
2 | tristate "SDMC DM1105 based PCI cards" | 2 | tristate "SDMC DM1105 based PCI cards" |
3 | depends on DVB_CORE && PCI && I2C | 3 | depends on DVB_CORE && PCI && I2C |
4 | depends on INPUT | ||
4 | select DVB_PLL if !DVB_FE_CUSTOMISE | 5 | select DVB_PLL if !DVB_FE_CUSTOMISE |
5 | select DVB_STV0299 if !DVB_FE_CUSTOMISE | 6 | select DVB_STV0299 if !DVB_FE_CUSTOMISE |
6 | select DVB_STV0288 if !DVB_FE_CUSTOMISE | 7 | select DVB_STV0288 if !DVB_FE_CUSTOMISE |
diff --git a/drivers/media/dvb/dvb-core/dvb_frontend.c b/drivers/media/dvb/dvb-core/dvb_frontend.c index 171f9ca124f7..843407785083 100644 --- a/drivers/media/dvb/dvb-core/dvb_frontend.c +++ b/drivers/media/dvb/dvb-core/dvb_frontend.c | |||
@@ -824,7 +824,7 @@ static int dvb_frontend_check_parameters(struct dvb_frontend *fe, | |||
824 | return 0; | 824 | return 0; |
825 | } | 825 | } |
826 | 826 | ||
827 | struct dtv_cmds_h dtv_cmds[] = { | 827 | static struct dtv_cmds_h dtv_cmds[] = { |
828 | [DTV_TUNE] = { | 828 | [DTV_TUNE] = { |
829 | .name = "DTV_TUNE", | 829 | .name = "DTV_TUNE", |
830 | .cmd = DTV_TUNE, | 830 | .cmd = DTV_TUNE, |
@@ -962,7 +962,7 @@ struct dtv_cmds_h dtv_cmds[] = { | |||
962 | }, | 962 | }, |
963 | }; | 963 | }; |
964 | 964 | ||
965 | void dtv_property_dump(struct dtv_property *tvp) | 965 | static void dtv_property_dump(struct dtv_property *tvp) |
966 | { | 966 | { |
967 | int i; | 967 | int i; |
968 | 968 | ||
@@ -993,7 +993,7 @@ void dtv_property_dump(struct dtv_property *tvp) | |||
993 | dprintk("%s() tvp.u.data = 0x%08x\n", __func__, tvp->u.data); | 993 | dprintk("%s() tvp.u.data = 0x%08x\n", __func__, tvp->u.data); |
994 | } | 994 | } |
995 | 995 | ||
996 | int is_legacy_delivery_system(fe_delivery_system_t s) | 996 | static int is_legacy_delivery_system(fe_delivery_system_t s) |
997 | { | 997 | { |
998 | if((s == SYS_UNDEFINED) || (s == SYS_DVBC_ANNEX_AC) || | 998 | if((s == SYS_UNDEFINED) || (s == SYS_DVBC_ANNEX_AC) || |
999 | (s == SYS_DVBC_ANNEX_B) || (s == SYS_DVBT) || (s == SYS_DVBS) || | 999 | (s == SYS_DVBC_ANNEX_B) || (s == SYS_DVBT) || (s == SYS_DVBS) || |
@@ -1007,7 +1007,8 @@ int is_legacy_delivery_system(fe_delivery_system_t s) | |||
1007 | * drivers can use a single set_frontend tuning function, regardless of whether | 1007 | * drivers can use a single set_frontend tuning function, regardless of whether |
1008 | * it's being used for the legacy or new API, reducing code and complexity. | 1008 | * it's being used for the legacy or new API, reducing code and complexity. |
1009 | */ | 1009 | */ |
1010 | void dtv_property_cache_sync(struct dvb_frontend *fe, struct dvb_frontend_parameters *p) | 1010 | static void dtv_property_cache_sync(struct dvb_frontend *fe, |
1011 | struct dvb_frontend_parameters *p) | ||
1011 | { | 1012 | { |
1012 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; | 1013 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; |
1013 | 1014 | ||
@@ -1059,7 +1060,7 @@ void dtv_property_cache_sync(struct dvb_frontend *fe, struct dvb_frontend_parame | |||
1059 | /* Ensure the cached values are set correctly in the frontend | 1060 | /* Ensure the cached values are set correctly in the frontend |
1060 | * legacy tuning structures, for the advanced tuning API. | 1061 | * legacy tuning structures, for the advanced tuning API. |
1061 | */ | 1062 | */ |
1062 | void dtv_property_legacy_params_sync(struct dvb_frontend *fe) | 1063 | static void dtv_property_legacy_params_sync(struct dvb_frontend *fe) |
1063 | { | 1064 | { |
1064 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; | 1065 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; |
1065 | struct dvb_frontend_private *fepriv = fe->frontend_priv; | 1066 | struct dvb_frontend_private *fepriv = fe->frontend_priv; |
@@ -1114,7 +1115,7 @@ void dtv_property_legacy_params_sync(struct dvb_frontend *fe) | |||
1114 | /* Ensure the cached values are set correctly in the frontend | 1115 | /* Ensure the cached values are set correctly in the frontend |
1115 | * legacy tuning structures, for the legacy tuning API. | 1116 | * legacy tuning structures, for the legacy tuning API. |
1116 | */ | 1117 | */ |
1117 | void dtv_property_adv_params_sync(struct dvb_frontend *fe) | 1118 | static void dtv_property_adv_params_sync(struct dvb_frontend *fe) |
1118 | { | 1119 | { |
1119 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; | 1120 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; |
1120 | struct dvb_frontend_private *fepriv = fe->frontend_priv; | 1121 | struct dvb_frontend_private *fepriv = fe->frontend_priv; |
@@ -1149,7 +1150,7 @@ void dtv_property_adv_params_sync(struct dvb_frontend *fe) | |||
1149 | } | 1150 | } |
1150 | } | 1151 | } |
1151 | 1152 | ||
1152 | void dtv_property_cache_submit(struct dvb_frontend *fe) | 1153 | static void dtv_property_cache_submit(struct dvb_frontend *fe) |
1153 | { | 1154 | { |
1154 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; | 1155 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; |
1155 | 1156 | ||
@@ -1180,8 +1181,9 @@ static int dvb_frontend_ioctl_legacy(struct inode *inode, struct file *file, | |||
1180 | static int dvb_frontend_ioctl_properties(struct inode *inode, struct file *file, | 1181 | static int dvb_frontend_ioctl_properties(struct inode *inode, struct file *file, |
1181 | unsigned int cmd, void *parg); | 1182 | unsigned int cmd, void *parg); |
1182 | 1183 | ||
1183 | int dtv_property_process_get(struct dvb_frontend *fe, struct dtv_property *tvp, | 1184 | static int dtv_property_process_get(struct dvb_frontend *fe, |
1184 | struct inode *inode, struct file *file) | 1185 | struct dtv_property *tvp, |
1186 | struct inode *inode, struct file *file) | ||
1185 | { | 1187 | { |
1186 | int r = 0; | 1188 | int r = 0; |
1187 | 1189 | ||
@@ -1253,8 +1255,10 @@ int dtv_property_process_get(struct dvb_frontend *fe, struct dtv_property *tvp, | |||
1253 | return r; | 1255 | return r; |
1254 | } | 1256 | } |
1255 | 1257 | ||
1256 | int dtv_property_process_set(struct dvb_frontend *fe, struct dtv_property *tvp, | 1258 | static int dtv_property_process_set(struct dvb_frontend *fe, |
1257 | struct inode *inode, struct file *file) | 1259 | struct dtv_property *tvp, |
1260 | struct inode *inode, | ||
1261 | struct file *file) | ||
1258 | { | 1262 | { |
1259 | int r = 0; | 1263 | int r = 0; |
1260 | struct dvb_frontend_private *fepriv = fe->frontend_priv; | 1264 | struct dvb_frontend_private *fepriv = fe->frontend_priv; |
diff --git a/drivers/media/dvb/dvb-usb/anysee.c b/drivers/media/dvb/dvb-usb/anysee.c index 5017f08b14a6..c6e7b4215d6b 100644 --- a/drivers/media/dvb/dvb-usb/anysee.c +++ b/drivers/media/dvb/dvb-usb/anysee.c | |||
@@ -41,7 +41,7 @@ | |||
41 | static int dvb_usb_anysee_debug; | 41 | static int dvb_usb_anysee_debug; |
42 | module_param_named(debug, dvb_usb_anysee_debug, int, 0644); | 42 | module_param_named(debug, dvb_usb_anysee_debug, int, 0644); |
43 | MODULE_PARM_DESC(debug, "set debugging level" DVB_USB_DEBUG_STATUS); | 43 | MODULE_PARM_DESC(debug, "set debugging level" DVB_USB_DEBUG_STATUS); |
44 | int dvb_usb_anysee_delsys; | 44 | static int dvb_usb_anysee_delsys; |
45 | module_param_named(delsys, dvb_usb_anysee_delsys, int, 0644); | 45 | module_param_named(delsys, dvb_usb_anysee_delsys, int, 0644); |
46 | MODULE_PARM_DESC(delsys, "select delivery mode (0=DVB-C, 1=DVB-T)"); | 46 | MODULE_PARM_DESC(delsys, "select delivery mode (0=DVB-C, 1=DVB-T)"); |
47 | DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr); | 47 | DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr); |
diff --git a/drivers/media/dvb/frontends/cx24116.c b/drivers/media/dvb/frontends/cx24116.c index 4f514d39b98f..28ad609e73f4 100644 --- a/drivers/media/dvb/frontends/cx24116.c +++ b/drivers/media/dvb/frontends/cx24116.c | |||
@@ -369,7 +369,7 @@ static int cx24116_set_inversion(struct cx24116_state *state, | |||
369 | * Not all S2 mmodulation schemes are support and not all rates with | 369 | * Not all S2 mmodulation schemes are support and not all rates with |
370 | * a scheme are support. Especially, no auto detect when in S2 mode. | 370 | * a scheme are support. Especially, no auto detect when in S2 mode. |
371 | */ | 371 | */ |
372 | struct cx24116_modfec { | 372 | static struct cx24116_modfec { |
373 | fe_delivery_system_t delivery_system; | 373 | fe_delivery_system_t delivery_system; |
374 | fe_modulation_t modulation; | 374 | fe_modulation_t modulation; |
375 | fe_code_rate_t fec; | 375 | fe_code_rate_t fec; |
diff --git a/drivers/media/dvb/frontends/stb0899_algo.c b/drivers/media/dvb/frontends/stb0899_algo.c index ced9b7ae7d50..83dc7e12d5f0 100644 --- a/drivers/media/dvb/frontends/stb0899_algo.c +++ b/drivers/media/dvb/frontends/stb0899_algo.c | |||
@@ -54,7 +54,7 @@ static u32 stb0899_calc_srate(u32 master_clk, u8 *sfr) | |||
54 | * stb0899_get_srate | 54 | * stb0899_get_srate |
55 | * Get the current symbol rate | 55 | * Get the current symbol rate |
56 | */ | 56 | */ |
57 | u32 stb0899_get_srate(struct stb0899_state *state) | 57 | static u32 stb0899_get_srate(struct stb0899_state *state) |
58 | { | 58 | { |
59 | struct stb0899_internal *internal = &state->internal; | 59 | struct stb0899_internal *internal = &state->internal; |
60 | u8 sfr[3]; | 60 | u8 sfr[3]; |
@@ -763,7 +763,7 @@ static void stb0899_dvbs2_config_csm_auto(struct stb0899_state *state) | |||
763 | stb0899_write_s2reg(state, STB0899_S2DEMOD, STB0899_BASE_CSM_CNTRL1, STB0899_OFF0_CSM_CNTRL1, reg); | 763 | stb0899_write_s2reg(state, STB0899_S2DEMOD, STB0899_BASE_CSM_CNTRL1, STB0899_OFF0_CSM_CNTRL1, reg); |
764 | } | 764 | } |
765 | 765 | ||
766 | long Log2Int(int number) | 766 | static long Log2Int(int number) |
767 | { | 767 | { |
768 | int i; | 768 | int i; |
769 | 769 | ||
diff --git a/drivers/media/dvb/frontends/stb0899_drv.c b/drivers/media/dvb/frontends/stb0899_drv.c index bee28f77b93f..10613acf18f5 100644 --- a/drivers/media/dvb/frontends/stb0899_drv.c +++ b/drivers/media/dvb/frontends/stb0899_drv.c | |||
@@ -134,7 +134,7 @@ static const struct stb0899_tab stb0899_dvbs2rf_tab[] = { | |||
134 | }; | 134 | }; |
135 | 135 | ||
136 | /* DVB-S2 Es/N0 quant in dB/100 vs read value * 100*/ | 136 | /* DVB-S2 Es/N0 quant in dB/100 vs read value * 100*/ |
137 | struct stb0899_tab stb0899_quant_tab[] = { | 137 | static struct stb0899_tab stb0899_quant_tab[] = { |
138 | { 0, 0 }, | 138 | { 0, 0 }, |
139 | { 0, 100 }, | 139 | { 0, 100 }, |
140 | { 600, 200 }, | 140 | { 600, 200 }, |
@@ -177,7 +177,7 @@ struct stb0899_tab stb0899_quant_tab[] = { | |||
177 | }; | 177 | }; |
178 | 178 | ||
179 | /* DVB-S2 Es/N0 estimate in dB/100 vs read value */ | 179 | /* DVB-S2 Es/N0 estimate in dB/100 vs read value */ |
180 | struct stb0899_tab stb0899_est_tab[] = { | 180 | static struct stb0899_tab stb0899_est_tab[] = { |
181 | { 0, 0 }, | 181 | { 0, 0 }, |
182 | { 0, 1 }, | 182 | { 0, 1 }, |
183 | { 301, 2 }, | 183 | { 301, 2 }, |
@@ -217,7 +217,7 @@ struct stb0899_tab stb0899_est_tab[] = { | |||
217 | { 5721, 526017 }, | 217 | { 5721, 526017 }, |
218 | }; | 218 | }; |
219 | 219 | ||
220 | int _stb0899_read_reg(struct stb0899_state *state, unsigned int reg) | 220 | static int _stb0899_read_reg(struct stb0899_state *state, unsigned int reg) |
221 | { | 221 | { |
222 | int ret; | 222 | int ret; |
223 | 223 | ||
diff --git a/drivers/media/dvb/ttpci/budget-ci.c b/drivers/media/dvb/ttpci/budget-ci.c index 4d2a5cf27c31..bcbc5d41a0fe 100644 --- a/drivers/media/dvb/ttpci/budget-ci.c +++ b/drivers/media/dvb/ttpci/budget-ci.c | |||
@@ -1337,7 +1337,7 @@ static struct stb0899_config tt3200_config = { | |||
1337 | .tuner_set_rfsiggain = NULL | 1337 | .tuner_set_rfsiggain = NULL |
1338 | }; | 1338 | }; |
1339 | 1339 | ||
1340 | struct stb6100_config tt3200_stb6100_config = { | 1340 | static struct stb6100_config tt3200_stb6100_config = { |
1341 | .tuner_address = 0x60, | 1341 | .tuner_address = 0x60, |
1342 | .refclock = 27000000, | 1342 | .refclock = 27000000, |
1343 | }; | 1343 | }; |
diff --git a/drivers/media/video/cx88/Kconfig b/drivers/media/video/cx88/Kconfig index b0f837588e01..2d250a2a7bc3 100644 --- a/drivers/media/video/cx88/Kconfig +++ b/drivers/media/video/cx88/Kconfig | |||
@@ -69,6 +69,11 @@ config VIDEO_CX88_DVB | |||
69 | To compile this driver as a module, choose M here: the | 69 | To compile this driver as a module, choose M here: the |
70 | module will be called cx88-dvb. | 70 | module will be called cx88-dvb. |
71 | 71 | ||
72 | config VIDEO_CX88_MPEG | ||
73 | tristate | ||
74 | depends on VIDEO_CX88_DVB || VIDEO_CX88_BLACKBIRD | ||
75 | default y | ||
76 | |||
72 | config VIDEO_CX88_VP3054 | 77 | config VIDEO_CX88_VP3054 |
73 | tristate "VP-3054 Secondary I2C Bus Support" | 78 | tristate "VP-3054 Secondary I2C Bus Support" |
74 | default m | 79 | default m |
diff --git a/drivers/media/video/cx88/Makefile b/drivers/media/video/cx88/Makefile index 6ec30f242578..b06b1275a9ec 100644 --- a/drivers/media/video/cx88/Makefile +++ b/drivers/media/video/cx88/Makefile | |||
@@ -3,7 +3,8 @@ cx88xx-objs := cx88-cards.o cx88-core.o cx88-i2c.o cx88-tvaudio.o \ | |||
3 | cx8800-objs := cx88-video.o cx88-vbi.o | 3 | cx8800-objs := cx88-video.o cx88-vbi.o |
4 | cx8802-objs := cx88-mpeg.o | 4 | cx8802-objs := cx88-mpeg.o |
5 | 5 | ||
6 | obj-$(CONFIG_VIDEO_CX88) += cx88xx.o cx8800.o cx8802.o | 6 | obj-$(CONFIG_VIDEO_CX88) += cx88xx.o cx8800.o |
7 | obj-$(CONFIG_VIDEO_CX88_MPEG) += cx8802.o | ||
7 | obj-$(CONFIG_VIDEO_CX88_ALSA) += cx88-alsa.o | 8 | obj-$(CONFIG_VIDEO_CX88_ALSA) += cx88-alsa.o |
8 | obj-$(CONFIG_VIDEO_CX88_BLACKBIRD) += cx88-blackbird.o | 9 | obj-$(CONFIG_VIDEO_CX88_BLACKBIRD) += cx88-blackbird.o |
9 | obj-$(CONFIG_VIDEO_CX88_DVB) += cx88-dvb.o | 10 | obj-$(CONFIG_VIDEO_CX88_DVB) += cx88-dvb.o |
diff --git a/drivers/media/video/cx88/cx88-dvb.c b/drivers/media/video/cx88/cx88-dvb.c index da4dd4913d9f..613dfea4ff3e 100644 --- a/drivers/media/video/cx88/cx88-dvb.c +++ b/drivers/media/video/cx88/cx88-dvb.c | |||
@@ -138,6 +138,28 @@ static int cx88_dvb_bus_ctrl(struct dvb_frontend* fe, int acquire) | |||
138 | return ret; | 138 | return ret; |
139 | } | 139 | } |
140 | 140 | ||
141 | static void cx88_dvb_gate_ctrl(struct cx88_core *core, int open) | ||
142 | { | ||
143 | struct videobuf_dvb_frontends *f; | ||
144 | struct videobuf_dvb_frontend *fe; | ||
145 | |||
146 | if (!core->dvbdev) | ||
147 | return; | ||
148 | |||
149 | f = &core->dvbdev->frontends; | ||
150 | |||
151 | if (!f) | ||
152 | return; | ||
153 | |||
154 | if (f->gate <= 1) /* undefined or fe0 */ | ||
155 | fe = videobuf_dvb_get_frontend(f, 1); | ||
156 | else | ||
157 | fe = videobuf_dvb_get_frontend(f, f->gate); | ||
158 | |||
159 | if (fe && fe->dvb.frontend && fe->dvb.frontend->ops.i2c_gate_ctrl) | ||
160 | fe->dvb.frontend->ops.i2c_gate_ctrl(fe->dvb.frontend, open); | ||
161 | } | ||
162 | |||
141 | /* ------------------------------------------------------------------ */ | 163 | /* ------------------------------------------------------------------ */ |
142 | 164 | ||
143 | static int dvico_fusionhdtv_demod_init(struct dvb_frontend* fe) | 165 | static int dvico_fusionhdtv_demod_init(struct dvb_frontend* fe) |
@@ -597,12 +619,30 @@ static int dvb_register(struct cx8802_dev *dev) | |||
597 | struct cx88_core *core = dev->core; | 619 | struct cx88_core *core = dev->core; |
598 | struct videobuf_dvb_frontend *fe0, *fe1 = NULL; | 620 | struct videobuf_dvb_frontend *fe0, *fe1 = NULL; |
599 | int mfe_shared = 0; /* bus not shared by default */ | 621 | int mfe_shared = 0; /* bus not shared by default */ |
622 | int i; | ||
600 | 623 | ||
601 | if (0 != core->i2c_rc) { | 624 | if (0 != core->i2c_rc) { |
602 | printk(KERN_ERR "%s/2: no i2c-bus available, cannot attach dvb drivers\n", core->name); | 625 | printk(KERN_ERR "%s/2: no i2c-bus available, cannot attach dvb drivers\n", core->name); |
603 | goto frontend_detach; | 626 | goto frontend_detach; |
604 | } | 627 | } |
605 | 628 | ||
629 | if (!core->board.num_frontends) | ||
630 | return -EINVAL; | ||
631 | |||
632 | mutex_init(&dev->frontends.lock); | ||
633 | INIT_LIST_HEAD(&dev->frontends.felist); | ||
634 | |||
635 | printk(KERN_INFO "%s() allocating %d frontend(s)\n", __func__, | ||
636 | core->board.num_frontends); | ||
637 | for (i = 1; i <= core->board.num_frontends; i++) { | ||
638 | fe0 = videobuf_dvb_alloc_frontend(&dev->frontends, i); | ||
639 | if (!fe0) { | ||
640 | printk(KERN_ERR "%s() failed to alloc\n", __func__); | ||
641 | videobuf_dvb_dealloc_frontends(&dev->frontends); | ||
642 | goto frontend_detach; | ||
643 | } | ||
644 | } | ||
645 | |||
606 | /* Get the first frontend */ | 646 | /* Get the first frontend */ |
607 | fe0 = videobuf_dvb_get_frontend(&dev->frontends, 1); | 647 | fe0 = videobuf_dvb_get_frontend(&dev->frontends, 1); |
608 | if (!fe0) | 648 | if (!fe0) |
@@ -611,6 +651,9 @@ static int dvb_register(struct cx8802_dev *dev) | |||
611 | /* multi-frontend gate control is undefined or defaults to fe0 */ | 651 | /* multi-frontend gate control is undefined or defaults to fe0 */ |
612 | dev->frontends.gate = 0; | 652 | dev->frontends.gate = 0; |
613 | 653 | ||
654 | /* Sets the gate control callback to be used by i2c command calls */ | ||
655 | core->gate_ctrl = cx88_dvb_gate_ctrl; | ||
656 | |||
614 | /* init frontend(s) */ | 657 | /* init frontend(s) */ |
615 | switch (core->boardnr) { | 658 | switch (core->boardnr) { |
616 | case CX88_BOARD_HAUPPAUGE_DVB_T1: | 659 | case CX88_BOARD_HAUPPAUGE_DVB_T1: |
@@ -1109,6 +1152,7 @@ static int dvb_register(struct cx8802_dev *dev) | |||
1109 | &dev->pci->dev, adapter_nr, mfe_shared); | 1152 | &dev->pci->dev, adapter_nr, mfe_shared); |
1110 | 1153 | ||
1111 | frontend_detach: | 1154 | frontend_detach: |
1155 | core->gate_ctrl = NULL; | ||
1112 | videobuf_dvb_dealloc_frontends(&dev->frontends); | 1156 | videobuf_dvb_dealloc_frontends(&dev->frontends); |
1113 | return -EINVAL; | 1157 | return -EINVAL; |
1114 | } | 1158 | } |
@@ -1270,6 +1314,8 @@ static int cx8802_dvb_remove(struct cx8802_driver *drv) | |||
1270 | 1314 | ||
1271 | vp3054_i2c_remove(dev); | 1315 | vp3054_i2c_remove(dev); |
1272 | 1316 | ||
1317 | core->gate_ctrl = NULL; | ||
1318 | |||
1273 | return 0; | 1319 | return 0; |
1274 | } | 1320 | } |
1275 | 1321 | ||
diff --git a/drivers/media/video/cx88/cx88-i2c.c b/drivers/media/video/cx88/cx88-i2c.c index 1ab691d20692..c0ff2305d804 100644 --- a/drivers/media/video/cx88/cx88-i2c.c +++ b/drivers/media/video/cx88/cx88-i2c.c | |||
@@ -116,30 +116,16 @@ static int detach_inform(struct i2c_client *client) | |||
116 | 116 | ||
117 | void cx88_call_i2c_clients(struct cx88_core *core, unsigned int cmd, void *arg) | 117 | void cx88_call_i2c_clients(struct cx88_core *core, unsigned int cmd, void *arg) |
118 | { | 118 | { |
119 | #if defined(CONFIG_VIDEO_CX88_DVB) || defined(CONFIG_VIDEO_CX88_DVB_MODULE) | ||
120 | struct videobuf_dvb_frontends *f = &core->dvbdev->frontends; | ||
121 | struct videobuf_dvb_frontend *fe = NULL; | ||
122 | #endif | ||
123 | if (0 != core->i2c_rc) | 119 | if (0 != core->i2c_rc) |
124 | return; | 120 | return; |
125 | 121 | ||
126 | #if defined(CONFIG_VIDEO_CX88_DVB) || defined(CONFIG_VIDEO_CX88_DVB_MODULE) | 122 | if (core->gate_ctrl) |
127 | if (core->dvbdev && f) { | 123 | core->gate_ctrl(core, 1); |
128 | if(f->gate <= 1) /* undefined or fe0 */ | ||
129 | fe = videobuf_dvb_get_frontend(f, 1); | ||
130 | else | ||
131 | fe = videobuf_dvb_get_frontend(f, f->gate); | ||
132 | 124 | ||
133 | if (fe && fe->dvb.frontend && fe->dvb.frontend->ops.i2c_gate_ctrl) | 125 | i2c_clients_command(&core->i2c_adap, cmd, arg); |
134 | fe->dvb.frontend->ops.i2c_gate_ctrl(fe->dvb.frontend, 1); | ||
135 | 126 | ||
136 | i2c_clients_command(&core->i2c_adap, cmd, arg); | 127 | if (core->gate_ctrl) |
137 | 128 | core->gate_ctrl(core, 0); | |
138 | if (fe && fe->dvb.frontend && fe->dvb.frontend->ops.i2c_gate_ctrl) | ||
139 | fe->dvb.frontend->ops.i2c_gate_ctrl(fe->dvb.frontend, 0); | ||
140 | } else | ||
141 | #endif | ||
142 | i2c_clients_command(&core->i2c_adap, cmd, arg); | ||
143 | } | 129 | } |
144 | 130 | ||
145 | static const struct i2c_algo_bit_data cx8800_i2c_algo_template = { | 131 | static const struct i2c_algo_bit_data cx8800_i2c_algo_template = { |
diff --git a/drivers/media/video/cx88/cx88-mpeg.c b/drivers/media/video/cx88/cx88-mpeg.c index 59164fc94f5f..b295b76737e3 100644 --- a/drivers/media/video/cx88/cx88-mpeg.c +++ b/drivers/media/video/cx88/cx88-mpeg.c | |||
@@ -787,6 +787,9 @@ static int __devinit cx8802_probe(struct pci_dev *pci_dev, | |||
787 | dev->pci = pci_dev; | 787 | dev->pci = pci_dev; |
788 | dev->core = core; | 788 | dev->core = core; |
789 | 789 | ||
790 | /* Maintain a reference so cx88-video can query the 8802 device. */ | ||
791 | core->dvbdev = dev; | ||
792 | |||
790 | err = cx8802_init_common(dev); | 793 | err = cx8802_init_common(dev); |
791 | if (err != 0) | 794 | if (err != 0) |
792 | goto fail_free; | 795 | goto fail_free; |
@@ -794,32 +797,6 @@ static int __devinit cx8802_probe(struct pci_dev *pci_dev, | |||
794 | INIT_LIST_HEAD(&dev->drvlist); | 797 | INIT_LIST_HEAD(&dev->drvlist); |
795 | list_add_tail(&dev->devlist,&cx8802_devlist); | 798 | list_add_tail(&dev->devlist,&cx8802_devlist); |
796 | 799 | ||
797 | #if defined(CONFIG_VIDEO_CX88_DVB) || defined(CONFIG_VIDEO_CX88_DVB_MODULE) | ||
798 | mutex_init(&dev->frontends.lock); | ||
799 | INIT_LIST_HEAD(&dev->frontends.felist); | ||
800 | |||
801 | if (core->board.num_frontends) { | ||
802 | struct videobuf_dvb_frontend *fe; | ||
803 | int i; | ||
804 | |||
805 | printk(KERN_INFO "%s() allocating %d frontend(s)\n", __func__, | ||
806 | core->board.num_frontends); | ||
807 | for (i = 1; i <= core->board.num_frontends; i++) { | ||
808 | fe = videobuf_dvb_alloc_frontend(&dev->frontends, i); | ||
809 | if(fe == NULL) { | ||
810 | printk(KERN_ERR "%s() failed to alloc\n", | ||
811 | __func__); | ||
812 | videobuf_dvb_dealloc_frontends(&dev->frontends); | ||
813 | err = -ENOMEM; | ||
814 | goto fail_free; | ||
815 | } | ||
816 | } | ||
817 | } | ||
818 | #endif | ||
819 | |||
820 | /* Maintain a reference so cx88-video can query the 8802 device. */ | ||
821 | core->dvbdev = dev; | ||
822 | |||
823 | /* now autoload cx88-dvb or cx88-blackbird */ | 800 | /* now autoload cx88-dvb or cx88-blackbird */ |
824 | request_modules(dev); | 801 | request_modules(dev); |
825 | return 0; | 802 | return 0; |
@@ -827,6 +804,7 @@ static int __devinit cx8802_probe(struct pci_dev *pci_dev, | |||
827 | fail_free: | 804 | fail_free: |
828 | kfree(dev); | 805 | kfree(dev); |
829 | fail_core: | 806 | fail_core: |
807 | core->dvbdev = NULL; | ||
830 | cx88_core_put(core,pci_dev); | 808 | cx88_core_put(core,pci_dev); |
831 | return err; | 809 | return err; |
832 | } | 810 | } |
diff --git a/drivers/media/video/cx88/cx88.h b/drivers/media/video/cx88/cx88.h index eb9ce30dc5e6..60a8b3187f14 100644 --- a/drivers/media/video/cx88/cx88.h +++ b/drivers/media/video/cx88/cx88.h | |||
@@ -302,6 +302,7 @@ struct cx88_dmaqueue { | |||
302 | struct btcx_riscmem stopper; | 302 | struct btcx_riscmem stopper; |
303 | u32 count; | 303 | u32 count; |
304 | }; | 304 | }; |
305 | struct cx88_core; | ||
305 | 306 | ||
306 | struct cx88_core { | 307 | struct cx88_core { |
307 | struct list_head devlist; | 308 | struct list_head devlist; |
@@ -334,7 +335,8 @@ struct cx88_core { | |||
334 | 335 | ||
335 | /* config info -- dvb */ | 336 | /* config info -- dvb */ |
336 | #if defined(CONFIG_VIDEO_CX88_DVB) || defined(CONFIG_VIDEO_CX88_DVB_MODULE) | 337 | #if defined(CONFIG_VIDEO_CX88_DVB) || defined(CONFIG_VIDEO_CX88_DVB_MODULE) |
337 | int (*prev_set_voltage)(struct dvb_frontend* fe, fe_sec_voltage_t voltage); | 338 | int (*prev_set_voltage)(struct dvb_frontend *fe, fe_sec_voltage_t voltage); |
339 | void (*gate_ctrl)(struct cx88_core *core, int open); | ||
338 | #endif | 340 | #endif |
339 | 341 | ||
340 | /* state info */ | 342 | /* state info */ |
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c index e776699b62f9..ef9bf008a924 100644 --- a/drivers/media/video/em28xx/em28xx-cards.c +++ b/drivers/media/video/em28xx/em28xx-cards.c | |||
@@ -1842,7 +1842,7 @@ void em28xx_release_resources(struct em28xx *dev) | |||
1842 | * em28xx_init_dev() | 1842 | * em28xx_init_dev() |
1843 | * allocates and inits the device structs, registers i2c bus and v4l device | 1843 | * allocates and inits the device structs, registers i2c bus and v4l device |
1844 | */ | 1844 | */ |
1845 | int em28xx_init_dev(struct em28xx **devhandle, struct usb_device *udev, | 1845 | static int em28xx_init_dev(struct em28xx **devhandle, struct usb_device *udev, |
1846 | int minor) | 1846 | int minor) |
1847 | { | 1847 | { |
1848 | struct em28xx *dev = *devhandle; | 1848 | struct em28xx *dev = *devhandle; |
@@ -1990,8 +1990,7 @@ static int em28xx_usb_probe(struct usb_interface *interface, | |||
1990 | int check_interface = 1; | 1990 | int check_interface = 1; |
1991 | isoc_pipe = 1; | 1991 | isoc_pipe = 1; |
1992 | endpoint = &interface->cur_altsetting->endpoint[1].desc; | 1992 | endpoint = &interface->cur_altsetting->endpoint[1].desc; |
1993 | if (usb_endpoint_type(endpoint) != | 1993 | if (!usb_endpoint_xfer_isoc(endpoint)) |
1994 | USB_ENDPOINT_XFER_ISOC) | ||
1995 | check_interface = 0; | 1994 | check_interface = 0; |
1996 | 1995 | ||
1997 | if (usb_endpoint_dir_out(endpoint)) | 1996 | if (usb_endpoint_dir_out(endpoint)) |
diff --git a/drivers/media/video/em28xx/em28xx-core.c b/drivers/media/video/em28xx/em28xx-core.c index 819cceaa6ef4..eb5fb05fab22 100644 --- a/drivers/media/video/em28xx/em28xx-core.c +++ b/drivers/media/video/em28xx/em28xx-core.c | |||
@@ -393,7 +393,7 @@ static int em28xx_set_audio_source(struct em28xx *dev) | |||
393 | return ret; | 393 | return ret; |
394 | } | 394 | } |
395 | 395 | ||
396 | struct em28xx_vol_table outputs[] = { | 396 | static const struct em28xx_vol_table outputs[] = { |
397 | { EM28XX_AOUT_MASTER, AC97_MASTER_VOL }, | 397 | { EM28XX_AOUT_MASTER, AC97_MASTER_VOL }, |
398 | { EM28XX_AOUT_LINE, AC97_LINE_LEVEL_VOL }, | 398 | { EM28XX_AOUT_LINE, AC97_LINE_LEVEL_VOL }, |
399 | { EM28XX_AOUT_MONO, AC97_MASTER_MONO_VOL }, | 399 | { EM28XX_AOUT_MONO, AC97_MASTER_MONO_VOL }, |
diff --git a/drivers/media/video/em28xx/em28xx-input.c b/drivers/media/video/em28xx/em28xx-input.c index 42bbaf64aceb..0443afe09ff8 100644 --- a/drivers/media/video/em28xx/em28xx-input.c +++ b/drivers/media/video/em28xx/em28xx-input.c | |||
@@ -307,7 +307,7 @@ static void em28xx_ir_work(struct work_struct *work) | |||
307 | mod_timer(&ir->timer, jiffies + msecs_to_jiffies(ir->polling)); | 307 | mod_timer(&ir->timer, jiffies + msecs_to_jiffies(ir->polling)); |
308 | } | 308 | } |
309 | 309 | ||
310 | void em28xx_ir_start(struct em28xx_IR *ir) | 310 | static void em28xx_ir_start(struct em28xx_IR *ir) |
311 | { | 311 | { |
312 | setup_timer(&ir->timer, ir_timer, (unsigned long)ir); | 312 | setup_timer(&ir->timer, ir_timer, (unsigned long)ir); |
313 | INIT_WORK(&ir->work, em28xx_ir_work); | 313 | INIT_WORK(&ir->work, em28xx_ir_work); |
diff --git a/drivers/media/video/gspca/m5602/m5602_s5k83a.c b/drivers/media/video/gspca/m5602/m5602_s5k83a.c index af3f2dc2c702..ccea4a758464 100644 --- a/drivers/media/video/gspca/m5602/m5602_s5k83a.c +++ b/drivers/media/video/gspca/m5602/m5602_s5k83a.c | |||
@@ -113,7 +113,7 @@ int s5k83a_power_down(struct sd *sd) | |||
113 | return 0; | 113 | return 0; |
114 | } | 114 | } |
115 | 115 | ||
116 | void s5k83a_dump_registers(struct sd *sd) | 116 | static void s5k83a_dump_registers(struct sd *sd) |
117 | { | 117 | { |
118 | int address; | 118 | int address; |
119 | u8 page, old_page; | 119 | u8 page, old_page; |
diff --git a/drivers/media/video/pxa_camera.c b/drivers/media/video/pxa_camera.c index 9d33de22cc48..a1d6008efcbb 100644 --- a/drivers/media/video/pxa_camera.c +++ b/drivers/media/video/pxa_camera.c | |||
@@ -34,12 +34,10 @@ | |||
34 | 34 | ||
35 | #include <linux/videodev2.h> | 35 | #include <linux/videodev2.h> |
36 | 36 | ||
37 | #include <asm/dma.h> | 37 | #include <mach/dma.h> |
38 | #include <mach/pxa-regs.h> | 38 | #include <mach/pxa-regs.h> |
39 | #include <mach/camera.h> | 39 | #include <mach/camera.h> |
40 | 40 | ||
41 | #include "pxa_camera.h" | ||
42 | |||
43 | #define PXA_CAM_VERSION_CODE KERNEL_VERSION(0, 0, 5) | 41 | #define PXA_CAM_VERSION_CODE KERNEL_VERSION(0, 0, 5) |
44 | #define PXA_CAM_DRV_NAME "pxa27x-camera" | 42 | #define PXA_CAM_DRV_NAME "pxa27x-camera" |
45 | 43 | ||
diff --git a/drivers/media/video/pxa_camera.h b/drivers/media/video/pxa_camera.h deleted file mode 100644 index 89cbfc9a35c5..000000000000 --- a/drivers/media/video/pxa_camera.h +++ /dev/null | |||
@@ -1,95 +0,0 @@ | |||
1 | /* Camera Interface */ | ||
2 | #define CICR0 __REG(0x50000000) | ||
3 | #define CICR1 __REG(0x50000004) | ||
4 | #define CICR2 __REG(0x50000008) | ||
5 | #define CICR3 __REG(0x5000000C) | ||
6 | #define CICR4 __REG(0x50000010) | ||
7 | #define CISR __REG(0x50000014) | ||
8 | #define CIFR __REG(0x50000018) | ||
9 | #define CITOR __REG(0x5000001C) | ||
10 | #define CIBR0 __REG(0x50000028) | ||
11 | #define CIBR1 __REG(0x50000030) | ||
12 | #define CIBR2 __REG(0x50000038) | ||
13 | |||
14 | #define CICR0_DMAEN (1 << 31) /* DMA request enable */ | ||
15 | #define CICR0_PAR_EN (1 << 30) /* Parity enable */ | ||
16 | #define CICR0_SL_CAP_EN (1 << 29) /* Capture enable for slave mode */ | ||
17 | #define CICR0_ENB (1 << 28) /* Camera interface enable */ | ||
18 | #define CICR0_DIS (1 << 27) /* Camera interface disable */ | ||
19 | #define CICR0_SIM (0x7 << 24) /* Sensor interface mode mask */ | ||
20 | #define CICR0_TOM (1 << 9) /* Time-out mask */ | ||
21 | #define CICR0_RDAVM (1 << 8) /* Receive-data-available mask */ | ||
22 | #define CICR0_FEM (1 << 7) /* FIFO-empty mask */ | ||
23 | #define CICR0_EOLM (1 << 6) /* End-of-line mask */ | ||
24 | #define CICR0_PERRM (1 << 5) /* Parity-error mask */ | ||
25 | #define CICR0_QDM (1 << 4) /* Quick-disable mask */ | ||
26 | #define CICR0_CDM (1 << 3) /* Disable-done mask */ | ||
27 | #define CICR0_SOFM (1 << 2) /* Start-of-frame mask */ | ||
28 | #define CICR0_EOFM (1 << 1) /* End-of-frame mask */ | ||
29 | #define CICR0_FOM (1 << 0) /* FIFO-overrun mask */ | ||
30 | |||
31 | #define CICR1_TBIT (1 << 31) /* Transparency bit */ | ||
32 | #define CICR1_RGBT_CONV (0x3 << 29) /* RGBT conversion mask */ | ||
33 | #define CICR1_PPL (0x7ff << 15) /* Pixels per line mask */ | ||
34 | #define CICR1_RGB_CONV (0x7 << 12) /* RGB conversion mask */ | ||
35 | #define CICR1_RGB_F (1 << 11) /* RGB format */ | ||
36 | #define CICR1_YCBCR_F (1 << 10) /* YCbCr format */ | ||
37 | #define CICR1_RGB_BPP (0x7 << 7) /* RGB bis per pixel mask */ | ||
38 | #define CICR1_RAW_BPP (0x3 << 5) /* Raw bis per pixel mask */ | ||
39 | #define CICR1_COLOR_SP (0x3 << 3) /* Color space mask */ | ||
40 | #define CICR1_DW (0x7 << 0) /* Data width mask */ | ||
41 | |||
42 | #define CICR2_BLW (0xff << 24) /* Beginning-of-line pixel clock | ||
43 | wait count mask */ | ||
44 | #define CICR2_ELW (0xff << 16) /* End-of-line pixel clock | ||
45 | wait count mask */ | ||
46 | #define CICR2_HSW (0x3f << 10) /* Horizontal sync pulse width mask */ | ||
47 | #define CICR2_BFPW (0x3f << 3) /* Beginning-of-frame pixel clock | ||
48 | wait count mask */ | ||
49 | #define CICR2_FSW (0x7 << 0) /* Frame stabilization | ||
50 | wait count mask */ | ||
51 | |||
52 | #define CICR3_BFW (0xff << 24) /* Beginning-of-frame line clock | ||
53 | wait count mask */ | ||
54 | #define CICR3_EFW (0xff << 16) /* End-of-frame line clock | ||
55 | wait count mask */ | ||
56 | #define CICR3_VSW (0x3f << 10) /* Vertical sync pulse width mask */ | ||
57 | #define CICR3_BFPW (0x3f << 3) /* Beginning-of-frame pixel clock | ||
58 | wait count mask */ | ||
59 | #define CICR3_LPF (0x7ff << 0) /* Lines per frame mask */ | ||
60 | |||
61 | #define CICR4_MCLK_DLY (0x3 << 24) /* MCLK Data Capture Delay mask */ | ||
62 | #define CICR4_PCLK_EN (1 << 23) /* Pixel clock enable */ | ||
63 | #define CICR4_PCP (1 << 22) /* Pixel clock polarity */ | ||
64 | #define CICR4_HSP (1 << 21) /* Horizontal sync polarity */ | ||
65 | #define CICR4_VSP (1 << 20) /* Vertical sync polarity */ | ||
66 | #define CICR4_MCLK_EN (1 << 19) /* MCLK enable */ | ||
67 | #define CICR4_FR_RATE (0x7 << 8) /* Frame rate mask */ | ||
68 | #define CICR4_DIV (0xff << 0) /* Clock divisor mask */ | ||
69 | |||
70 | #define CISR_FTO (1 << 15) /* FIFO time-out */ | ||
71 | #define CISR_RDAV_2 (1 << 14) /* Channel 2 receive data available */ | ||
72 | #define CISR_RDAV_1 (1 << 13) /* Channel 1 receive data available */ | ||
73 | #define CISR_RDAV_0 (1 << 12) /* Channel 0 receive data available */ | ||
74 | #define CISR_FEMPTY_2 (1 << 11) /* Channel 2 FIFO empty */ | ||
75 | #define CISR_FEMPTY_1 (1 << 10) /* Channel 1 FIFO empty */ | ||
76 | #define CISR_FEMPTY_0 (1 << 9) /* Channel 0 FIFO empty */ | ||
77 | #define CISR_EOL (1 << 8) /* End of line */ | ||
78 | #define CISR_PAR_ERR (1 << 7) /* Parity error */ | ||
79 | #define CISR_CQD (1 << 6) /* Camera interface quick disable */ | ||
80 | #define CISR_CDD (1 << 5) /* Camera interface disable done */ | ||
81 | #define CISR_SOF (1 << 4) /* Start of frame */ | ||
82 | #define CISR_EOF (1 << 3) /* End of frame */ | ||
83 | #define CISR_IFO_2 (1 << 2) /* FIFO overrun for Channel 2 */ | ||
84 | #define CISR_IFO_1 (1 << 1) /* FIFO overrun for Channel 1 */ | ||
85 | #define CISR_IFO_0 (1 << 0) /* FIFO overrun for Channel 0 */ | ||
86 | |||
87 | #define CIFR_FLVL2 (0x7f << 23) /* FIFO 2 level mask */ | ||
88 | #define CIFR_FLVL1 (0x7f << 16) /* FIFO 1 level mask */ | ||
89 | #define CIFR_FLVL0 (0xff << 8) /* FIFO 0 level mask */ | ||
90 | #define CIFR_THL_0 (0x3 << 4) /* Threshold Level for Channel 0 FIFO */ | ||
91 | #define CIFR_RESET_F (1 << 3) /* Reset input FIFOs */ | ||
92 | #define CIFR_FEN2 (1 << 2) /* FIFO enable for channel 2 */ | ||
93 | #define CIFR_FEN1 (1 << 1) /* FIFO enable for channel 1 */ | ||
94 | #define CIFR_FEN0 (1 << 0) /* FIFO enable for channel 0 */ | ||
95 | |||
diff --git a/drivers/media/video/usbvideo/ibmcam.c b/drivers/media/video/usbvideo/ibmcam.c index f8d85ddb4804..b08549661781 100644 --- a/drivers/media/video/usbvideo/ibmcam.c +++ b/drivers/media/video/usbvideo/ibmcam.c | |||
@@ -3779,7 +3779,7 @@ static int ibmcam_probe(struct usb_interface *intf, const struct usb_device_id * | |||
3779 | err("Alternate settings have different endpoint addresses!"); | 3779 | err("Alternate settings have different endpoint addresses!"); |
3780 | return -ENODEV; | 3780 | return -ENODEV; |
3781 | } | 3781 | } |
3782 | if (usb_endpoint_type(endpoint) != USB_ENDPOINT_XFER_ISOC) { | 3782 | if (!usb_endpoint_xfer_isoc(endpoint)) { |
3783 | err("Interface %d. has non-ISO endpoint!", ifnum); | 3783 | err("Interface %d. has non-ISO endpoint!", ifnum); |
3784 | return -ENODEV; | 3784 | return -ENODEV; |
3785 | } | 3785 | } |
diff --git a/drivers/media/video/usbvideo/konicawc.c b/drivers/media/video/usbvideo/konicawc.c index 90f0ce6a26bc..900ec2129ca1 100644 --- a/drivers/media/video/usbvideo/konicawc.c +++ b/drivers/media/video/usbvideo/konicawc.c | |||
@@ -823,7 +823,7 @@ static int konicawc_probe(struct usb_interface *intf, const struct usb_device_id | |||
823 | err("Alternate settings have different endpoint addresses!"); | 823 | err("Alternate settings have different endpoint addresses!"); |
824 | return -ENODEV; | 824 | return -ENODEV; |
825 | } | 825 | } |
826 | if (usb_endpoint_type(endpoint) != USB_ENDPOINT_XFER_ISOC) { | 826 | if (!usb_endpoint_xfer_isoc(endpoint)) { |
827 | err("Interface %d. has non-ISO endpoint!", | 827 | err("Interface %d. has non-ISO endpoint!", |
828 | interface->desc.bInterfaceNumber); | 828 | interface->desc.bInterfaceNumber); |
829 | return -ENODEV; | 829 | return -ENODEV; |
diff --git a/drivers/media/video/usbvideo/ultracam.c b/drivers/media/video/usbvideo/ultracam.c index 839a08240c25..fbd1b6392290 100644 --- a/drivers/media/video/usbvideo/ultracam.c +++ b/drivers/media/video/usbvideo/ultracam.c | |||
@@ -556,7 +556,7 @@ static int ultracam_probe(struct usb_interface *intf, const struct usb_device_id | |||
556 | err("Alternate settings have different endpoint addresses!"); | 556 | err("Alternate settings have different endpoint addresses!"); |
557 | return -ENODEV; | 557 | return -ENODEV; |
558 | } | 558 | } |
559 | if (usb_endpoint_type(endpoint) != USB_ENDPOINT_XFER_ISOC) { | 559 | if (!usb_endpoint_xfer_isoc(endpoint)) { |
560 | err("Interface %d. has non-ISO endpoint!", | 560 | err("Interface %d. has non-ISO endpoint!", |
561 | interface->desc.bInterfaceNumber); | 561 | interface->desc.bInterfaceNumber); |
562 | return -ENODEV; | 562 | return -ENODEV; |
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c index 2be5e47ed081..2622de003a45 100644 --- a/drivers/media/video/usbvision/usbvision-video.c +++ b/drivers/media/video/usbvision/usbvision-video.c | |||
@@ -1674,8 +1674,7 @@ static int __devinit usbvision_probe(struct usb_interface *intf, | |||
1674 | interface = &dev->actconfig->interface[ifnum]->altsetting[0]; | 1674 | interface = &dev->actconfig->interface[ifnum]->altsetting[0]; |
1675 | } | 1675 | } |
1676 | endpoint = &interface->endpoint[1].desc; | 1676 | endpoint = &interface->endpoint[1].desc; |
1677 | if (usb_endpoint_type(endpoint) != | 1677 | if (!usb_endpoint_xfer_isoc(endpoint)) { |
1678 | USB_ENDPOINT_XFER_ISOC) { | ||
1679 | err("%s: interface %d. has non-ISO endpoint!", | 1678 | err("%s: interface %d. has non-ISO endpoint!", |
1680 | __func__, ifnum); | 1679 | __func__, ifnum); |
1681 | err("%s: Endpoint attributes %d", | 1680 | err("%s: Endpoint attributes %d", |
diff --git a/drivers/media/video/v4l2-device.c b/drivers/media/video/v4l2-device.c index 9eefde031597..cf9d4c7f571a 100644 --- a/drivers/media/video/v4l2-device.c +++ b/drivers/media/video/v4l2-device.c | |||
@@ -29,7 +29,7 @@ int v4l2_device_register(struct device *dev, struct v4l2_device *v4l2_dev) | |||
29 | if (dev == NULL || v4l2_dev == NULL) | 29 | if (dev == NULL || v4l2_dev == NULL) |
30 | return -EINVAL; | 30 | return -EINVAL; |
31 | /* Warn if we apparently re-register a device */ | 31 | /* Warn if we apparently re-register a device */ |
32 | WARN_ON(dev_get_drvdata(dev)); | 32 | WARN_ON(dev_get_drvdata(dev) != NULL); |
33 | INIT_LIST_HEAD(&v4l2_dev->subdevs); | 33 | INIT_LIST_HEAD(&v4l2_dev->subdevs); |
34 | spin_lock_init(&v4l2_dev->lock); | 34 | spin_lock_init(&v4l2_dev->lock); |
35 | v4l2_dev->dev = dev; | 35 | v4l2_dev->dev = dev; |
@@ -61,7 +61,7 @@ int v4l2_device_register_subdev(struct v4l2_device *dev, struct v4l2_subdev *sd) | |||
61 | if (dev == NULL || sd == NULL || !sd->name[0]) | 61 | if (dev == NULL || sd == NULL || !sd->name[0]) |
62 | return -EINVAL; | 62 | return -EINVAL; |
63 | /* Warn if we apparently re-register a subdev */ | 63 | /* Warn if we apparently re-register a subdev */ |
64 | WARN_ON(sd->dev); | 64 | WARN_ON(sd->dev != NULL); |
65 | if (!try_module_get(sd->owner)) | 65 | if (!try_module_get(sd->owner)) |
66 | return -ENODEV; | 66 | return -ENODEV; |
67 | sd->dev = dev; | 67 | sd->dev = dev; |
diff --git a/drivers/media/video/videobuf-dma-sg.c b/drivers/media/video/videobuf-dma-sg.c index bc6d5aba0fe6..da1790e57a86 100644 --- a/drivers/media/video/videobuf-dma-sg.c +++ b/drivers/media/video/videobuf-dma-sg.c | |||
@@ -388,8 +388,7 @@ videobuf_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf) | |||
388 | page = alloc_page(GFP_USER | __GFP_DMA32); | 388 | page = alloc_page(GFP_USER | __GFP_DMA32); |
389 | if (!page) | 389 | if (!page) |
390 | return VM_FAULT_OOM; | 390 | return VM_FAULT_OOM; |
391 | clear_user_page(page_address(page), (unsigned long)vmf->virtual_address, | 391 | clear_user_highpage(page, (unsigned long)vmf->virtual_address); |
392 | page); | ||
393 | vmf->page = page; | 392 | vmf->page = page; |
394 | return 0; | 393 | return 0; |
395 | } | 394 | } |
diff --git a/drivers/staging/go7007/go7007-v4l2.c b/drivers/staging/go7007/go7007-v4l2.c index 4f7237a03ad1..868edb65e7bf 100644 --- a/drivers/staging/go7007/go7007-v4l2.c +++ b/drivers/staging/go7007/go7007-v4l2.c | |||
@@ -1712,8 +1712,7 @@ static int go7007_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf) | |||
1712 | page = alloc_page(GFP_USER | __GFP_DMA32); | 1712 | page = alloc_page(GFP_USER | __GFP_DMA32); |
1713 | if (!page) | 1713 | if (!page) |
1714 | return VM_FAULT_OOM; | 1714 | return VM_FAULT_OOM; |
1715 | clear_user_page(page_address(page), (unsigned long)vmf->virtual_address, | 1715 | clear_user_highpage(page, (unsigned long)vmf->virtual_address); |
1716 | page); | ||
1717 | vmf->page = page; | 1716 | vmf->page = page; |
1718 | return 0; | 1717 | return 0; |
1719 | } | 1718 | } |