diff options
Diffstat (limited to 'drivers/media/dvb/frontends/l64781.c')
-rw-r--r-- | drivers/media/dvb/frontends/l64781.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/media/dvb/frontends/l64781.c b/drivers/media/dvb/frontends/l64781.c index 1c7c91224472..f3bc82e44a28 100644 --- a/drivers/media/dvb/frontends/l64781.c +++ b/drivers/media/dvb/frontends/l64781.c | |||
@@ -32,7 +32,6 @@ | |||
32 | 32 | ||
33 | struct l64781_state { | 33 | struct l64781_state { |
34 | struct i2c_adapter* i2c; | 34 | struct i2c_adapter* i2c; |
35 | struct dvb_frontend_ops ops; | ||
36 | const struct l64781_config* config; | 35 | const struct l64781_config* config; |
37 | struct dvb_frontend frontend; | 36 | struct dvb_frontend frontend; |
38 | 37 | ||
@@ -141,7 +140,10 @@ static int apply_frontend_param (struct dvb_frontend* fe, struct dvb_frontend_pa | |||
141 | u8 val0x06; | 140 | u8 val0x06; |
142 | int bw = p->bandwidth - BANDWIDTH_8_MHZ; | 141 | int bw = p->bandwidth - BANDWIDTH_8_MHZ; |
143 | 142 | ||
144 | state->config->pll_set(fe, param); | 143 | if (fe->ops.tuner_ops.set_params) { |
144 | fe->ops.tuner_ops.set_params(fe, param); | ||
145 | if (fe->ops.i2c_gate_ctrl) fe->ops.i2c_gate_ctrl(fe, 0); | ||
146 | } | ||
145 | 147 | ||
146 | if (param->inversion != INVERSION_ON && | 148 | if (param->inversion != INVERSION_ON && |
147 | param->inversion != INVERSION_OFF) | 149 | param->inversion != INVERSION_OFF) |
@@ -463,8 +465,6 @@ static int l64781_init(struct dvb_frontend* fe) | |||
463 | /* Everything is two's complement, soft bit and CSI_OUT too */ | 465 | /* Everything is two's complement, soft bit and CSI_OUT too */ |
464 | l64781_writereg (state, 0x1e, 0x09); | 466 | l64781_writereg (state, 0x1e, 0x09); |
465 | 467 | ||
466 | if (state->config->pll_init) state->config->pll_init(fe); | ||
467 | |||
468 | /* delay a bit after first init attempt */ | 468 | /* delay a bit after first init attempt */ |
469 | if (state->first) { | 469 | if (state->first) { |
470 | state->first = 0; | 470 | state->first = 0; |
@@ -508,7 +508,6 @@ struct dvb_frontend* l64781_attach(const struct l64781_config* config, | |||
508 | /* setup the state */ | 508 | /* setup the state */ |
509 | state->config = config; | 509 | state->config = config; |
510 | state->i2c = i2c; | 510 | state->i2c = i2c; |
511 | memcpy(&state->ops, &l64781_ops, sizeof(struct dvb_frontend_ops)); | ||
512 | state->first = 1; | 511 | state->first = 1; |
513 | 512 | ||
514 | /** | 513 | /** |
@@ -554,7 +553,7 @@ struct dvb_frontend* l64781_attach(const struct l64781_config* config, | |||
554 | } | 553 | } |
555 | 554 | ||
556 | /* create dvb_frontend */ | 555 | /* create dvb_frontend */ |
557 | state->frontend.ops = &state->ops; | 556 | memcpy(&state->frontend.ops, &l64781_ops, sizeof(struct dvb_frontend_ops)); |
558 | state->frontend.demodulator_priv = state; | 557 | state->frontend.demodulator_priv = state; |
559 | return &state->frontend; | 558 | return &state->frontend; |
560 | 559 | ||