diff options
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/dvb/frontends/mt352.c | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/drivers/media/dvb/frontends/mt352.c b/drivers/media/dvb/frontends/mt352.c index a7a347a3cad0..3c86018e7f9d 100644 --- a/drivers/media/dvb/frontends/mt352.c +++ b/drivers/media/dvb/frontends/mt352.c | |||
@@ -287,18 +287,32 @@ static int mt352_set_parameters(struct dvb_frontend* fe, | |||
287 | mt352_calc_nominal_rate(state, op->bandwidth, buf+4); | 287 | mt352_calc_nominal_rate(state, op->bandwidth, buf+4); |
288 | mt352_calc_input_freq(state, buf+6); | 288 | mt352_calc_input_freq(state, buf+6); |
289 | 289 | ||
290 | // if there is no secondary tuner, call set_params to set up a potential | ||
291 | // tuner attached elsewhere | ||
292 | if (state->config.no_tuner) { | ||
293 | if (fe->ops->tuner_ops.set_params) { | ||
294 | fe->ops->tuner_ops.set_params(fe, param); | ||
295 | if (fe->ops->i2c_gate_ctrl) fe->ops->i2c_gate_ctrl(fe, 0); | ||
296 | } | ||
297 | |||
298 | /* start decoding only */ | ||
299 | mt352_write(fe, fsm_go, 2); | ||
300 | } | ||
301 | |||
302 | // retrieve the pllbuf - we do this even if there is no | ||
303 | // secondary tuner simply so we have a record of what was sent for | ||
304 | // debugging. | ||
290 | if (fe->ops->tuner_ops.pllbuf) { | 305 | if (fe->ops->tuner_ops.pllbuf) { |
291 | fe->ops->tuner_ops.pllbuf(fe, param, buf+8, 5); | 306 | fe->ops->tuner_ops.pllbuf(fe, param, buf+8, 5); |
292 | buf[8] <<= 1; | 307 | buf[8] <<= 1; |
293 | mt352_write(fe, buf, sizeof(buf)); | 308 | mt352_write(fe, buf, sizeof(buf)); |
294 | } | 309 | } |
295 | if (state->config.no_tuner) { | 310 | |
296 | /* start decoding */ | 311 | // send PLL and start tuning and then decoding |
297 | mt352_write(fe, fsm_go, 2); | 312 | if (!state->config.no_tuner) { |
298 | } else { | ||
299 | /* start tuning */ | ||
300 | mt352_write(fe, tuner_go, 2); | 313 | mt352_write(fe, tuner_go, 2); |
301 | } | 314 | } |
315 | |||
302 | return 0; | 316 | return 0; |
303 | } | 317 | } |
304 | 318 | ||