aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2009-01-08 14:05:59 -0500
committerDavid S. Miller <davem@davemloft.net>2009-01-08 14:05:59 -0500
commit7f46b1343f723f98634a5dcee47856b2000079ed (patch)
treeed22b6298c8dd2f687890a0d79abcd1d273b5f81 /drivers/media/dvb
parentb8c31da64165b8566fc6e1c9c826f76e7b98ff02 (diff)
parent9e42d0cf5020aaf217433cad1a224745241d212a (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/media/dvb')
-rw-r--r--drivers/media/dvb/dm1105/Kconfig1
-rw-r--r--drivers/media/dvb/dvb-core/dvb_frontend.c26
-rw-r--r--drivers/media/dvb/dvb-core/dvbdev.c5
-rw-r--r--drivers/media/dvb/dvb-usb/anysee.c2
-rw-r--r--drivers/media/dvb/frontends/cx24116.c2
-rw-r--r--drivers/media/dvb/frontends/lgdt3304.c10
-rw-r--r--drivers/media/dvb/frontends/s921_module.c2
-rw-r--r--drivers/media/dvb/frontends/stb0899_algo.c4
-rw-r--r--drivers/media/dvb/frontends/stb0899_drv.c6
-rw-r--r--drivers/media/dvb/ttpci/budget-ci.c4
10 files changed, 36 insertions, 26 deletions
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 @@
1config DVB_DM1105 1config 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
827struct dtv_cmds_h dtv_cmds[] = { 827static 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
965void dtv_property_dump(struct dtv_property *tvp) 965static 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
996int is_legacy_delivery_system(fe_delivery_system_t s) 996static 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 */
1010void dtv_property_cache_sync(struct dvb_frontend *fe, struct dvb_frontend_parameters *p) 1010static 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 */
1062void dtv_property_legacy_params_sync(struct dvb_frontend *fe) 1063static 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 */
1117void dtv_property_adv_params_sync(struct dvb_frontend *fe) 1118static 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
1152void dtv_property_cache_submit(struct dvb_frontend *fe) 1153static 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,
1180static int dvb_frontend_ioctl_properties(struct inode *inode, struct file *file, 1181static 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
1183int dtv_property_process_get(struct dvb_frontend *fe, struct dtv_property *tvp, 1184static 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
1256int dtv_property_process_set(struct dvb_frontend *fe, struct dtv_property *tvp, 1258static 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-core/dvbdev.c b/drivers/media/dvb/dvb-core/dvbdev.c
index 65d69665f1fc..6a32680dbb1b 100644
--- a/drivers/media/dvb/dvb-core/dvbdev.c
+++ b/drivers/media/dvb/dvb-core/dvbdev.c
@@ -79,6 +79,10 @@ static int dvb_device_open(struct inode *inode, struct file *file)
79 file->private_data = dvbdev; 79 file->private_data = dvbdev;
80 old_fops = file->f_op; 80 old_fops = file->f_op;
81 file->f_op = fops_get(dvbdev->fops); 81 file->f_op = fops_get(dvbdev->fops);
82 if (file->f_op == NULL) {
83 file->f_op = old_fops;
84 goto fail;
85 }
82 if(file->f_op->open) 86 if(file->f_op->open)
83 err = file->f_op->open(inode,file); 87 err = file->f_op->open(inode,file);
84 if (err) { 88 if (err) {
@@ -90,6 +94,7 @@ static int dvb_device_open(struct inode *inode, struct file *file)
90 unlock_kernel(); 94 unlock_kernel();
91 return err; 95 return err;
92 } 96 }
97fail:
93 up_read(&minor_rwsem); 98 up_read(&minor_rwsem);
94 unlock_kernel(); 99 unlock_kernel();
95 return -ENODEV; 100 return -ENODEV;
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 @@
41static int dvb_usb_anysee_debug; 41static int dvb_usb_anysee_debug;
42module_param_named(debug, dvb_usb_anysee_debug, int, 0644); 42module_param_named(debug, dvb_usb_anysee_debug, int, 0644);
43MODULE_PARM_DESC(debug, "set debugging level" DVB_USB_DEBUG_STATUS); 43MODULE_PARM_DESC(debug, "set debugging level" DVB_USB_DEBUG_STATUS);
44int dvb_usb_anysee_delsys; 44static int dvb_usb_anysee_delsys;
45module_param_named(delsys, dvb_usb_anysee_delsys, int, 0644); 45module_param_named(delsys, dvb_usb_anysee_delsys, int, 0644);
46MODULE_PARM_DESC(delsys, "select delivery mode (0=DVB-C, 1=DVB-T)"); 46MODULE_PARM_DESC(delsys, "select delivery mode (0=DVB-C, 1=DVB-T)");
47DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr); 47DVB_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 */
372struct cx24116_modfec { 372static 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/lgdt3304.c b/drivers/media/dvb/frontends/lgdt3304.c
index 469ace5692c6..3bb0c4394f8a 100644
--- a/drivers/media/dvb/frontends/lgdt3304.c
+++ b/drivers/media/dvb/frontends/lgdt3304.c
@@ -42,7 +42,7 @@ static int i2c_write_demod_bytes (struct dvb_frontend *fe, __u8 *buf, int len)
42 42
43 for (i=0; i<len-1; i+=3){ 43 for (i=0; i<len-1; i+=3){
44 if((err = i2c_transfer(state->i2c, &i2cmsgs, 1))<0) { 44 if((err = i2c_transfer(state->i2c, &i2cmsgs, 1))<0) {
45 printk("%s i2c_transfer error %d\n", __FUNCTION__, err); 45 printk("%s i2c_transfer error %d\n", __func__, err);
46 if (err < 0) 46 if (err < 0)
47 return err; 47 return err;
48 else 48 else
@@ -73,7 +73,7 @@ static int lgdt3304_i2c_read_reg(struct dvb_frontend *fe, unsigned int reg)
73 i2cmsgs[1].buf = &buf; 73 i2cmsgs[1].buf = &buf;
74 74
75 if((ret = i2c_transfer(state->i2c, i2cmsgs, 2))<0) { 75 if((ret = i2c_transfer(state->i2c, i2cmsgs, 2))<0) {
76 printk("%s i2c_transfer error %d\n", __FUNCTION__, ret); 76 printk("%s i2c_transfer error %d\n", __func__, ret);
77 return ret; 77 return ret;
78 } 78 }
79 79
@@ -94,7 +94,7 @@ static int lgdt3304_i2c_write_reg(struct dvb_frontend *fe, int reg, int val)
94 }; 94 };
95 ret = i2c_transfer(state->i2c, &i2cmsgs, 1); 95 ret = i2c_transfer(state->i2c, &i2cmsgs, 1);
96 if (ret != 1) { 96 if (ret != 1) {
97 printk("%s i2c_transfer error %d\n", __FUNCTION__, ret); 97 printk("%s i2c_transfer error %d\n", __func__, ret);
98 return ret; 98 return ret;
99 } 99 }
100 100
@@ -238,7 +238,7 @@ static int lgdt3304_set_parameters(struct dvb_frontend *fe, struct dvb_frontend_
238 } 238 }
239 239
240 if (err) { 240 if (err) {
241 printk("%s error setting modulation\n", __FUNCTION__); 241 printk("%s error setting modulation\n", __func__);
242 } else { 242 } else {
243 state->current_modulation = param->u.vsb.modulation; 243 state->current_modulation = param->u.vsb.modulation;
244 } 244 }
@@ -305,7 +305,7 @@ static int lgdt3304_read_status(struct dvb_frontend *fe, fe_status_t *status)
305 } 305 }
306 break; 306 break;
307 default: 307 default:
308 printk("%s unhandled modulation\n", __FUNCTION__); 308 printk("%s unhandled modulation\n", __func__);
309 } 309 }
310 310
311 311
diff --git a/drivers/media/dvb/frontends/s921_module.c b/drivers/media/dvb/frontends/s921_module.c
index 3cbb9cb2cf47..892af8c9ed57 100644
--- a/drivers/media/dvb/frontends/s921_module.c
+++ b/drivers/media/dvb/frontends/s921_module.c
@@ -136,7 +136,7 @@ static int s921_write(void *dev, u8 reg, u8 val) {
136 }; 136 };
137 137
138 if((err = i2c_transfer(state->i2c, &i2cmsgs, 1))<0) { 138 if((err = i2c_transfer(state->i2c, &i2cmsgs, 1))<0) {
139 printk("%s i2c_transfer error %d\n", __FUNCTION__, err); 139 printk("%s i2c_transfer error %d\n", __func__, err);
140 if (err < 0) 140 if (err < 0)
141 return err; 141 return err;
142 else 142 else
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 */
57u32 stb0899_get_srate(struct stb0899_state *state) 57static 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
766long Log2Int(int number) 766static 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*/
137struct stb0899_tab stb0899_quant_tab[] = { 137static 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 */
180struct stb0899_tab stb0899_est_tab[] = { 180static 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
220int _stb0899_read_reg(struct stb0899_state *state, unsigned int reg) 220static 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 3507463fdac9..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
1340struct stb6100_config tt3200_stb6100_config = { 1340static struct stb6100_config tt3200_stb6100_config = {
1341 .tuner_address = 0x60, 1341 .tuner_address = 0x60,
1342 .refclock = 27000000, 1342 .refclock = 27000000,
1343}; 1343};
@@ -1450,7 +1450,7 @@ static void frontend_init(struct budget_ci *budget_ci)
1450 if (budget_ci->budget.dvb_frontend) { 1450 if (budget_ci->budget.dvb_frontend) {
1451 if (dvb_attach(stb6100_attach, budget_ci->budget.dvb_frontend, &tt3200_stb6100_config, &budget_ci->budget.i2c_adap)) { 1451 if (dvb_attach(stb6100_attach, budget_ci->budget.dvb_frontend, &tt3200_stb6100_config, &budget_ci->budget.i2c_adap)) {
1452 if (!dvb_attach(lnbp21_attach, budget_ci->budget.dvb_frontend, &budget_ci->budget.i2c_adap, 0, 0)) { 1452 if (!dvb_attach(lnbp21_attach, budget_ci->budget.dvb_frontend, &budget_ci->budget.i2c_adap, 0, 0)) {
1453 printk("%s: No LNBP21 found!\n", __FUNCTION__); 1453 printk("%s: No LNBP21 found!\n", __func__);
1454 dvb_frontend_detach(budget_ci->budget.dvb_frontend); 1454 dvb_frontend_detach(budget_ci->budget.dvb_frontend);
1455 budget_ci->budget.dvb_frontend = NULL; 1455 budget_ci->budget.dvb_frontend = NULL;
1456 } 1456 }