diff options
Diffstat (limited to 'drivers/media/dvb/frontends/nxt6000.c')
-rw-r--r-- | drivers/media/dvb/frontends/nxt6000.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/media/dvb/frontends/nxt6000.c b/drivers/media/dvb/frontends/nxt6000.c index bca83266ae8b..d313d7dcf386 100644 --- a/drivers/media/dvb/frontends/nxt6000.c +++ b/drivers/media/dvb/frontends/nxt6000.c | |||
@@ -33,7 +33,6 @@ | |||
33 | 33 | ||
34 | struct nxt6000_state { | 34 | struct nxt6000_state { |
35 | struct i2c_adapter* i2c; | 35 | struct i2c_adapter* i2c; |
36 | struct dvb_frontend_ops ops; | ||
37 | /* configuration settings */ | 36 | /* configuration settings */ |
38 | const struct nxt6000_config* config; | 37 | const struct nxt6000_config* config; |
39 | struct dvb_frontend frontend; | 38 | struct dvb_frontend frontend; |
@@ -463,9 +462,9 @@ static int nxt6000_set_frontend(struct dvb_frontend* fe, struct dvb_frontend_par | |||
463 | struct nxt6000_state* state = fe->demodulator_priv; | 462 | struct nxt6000_state* state = fe->demodulator_priv; |
464 | int result; | 463 | int result; |
465 | 464 | ||
466 | if (fe->ops->tuner_ops.set_params) { | 465 | if (fe->ops.tuner_ops.set_params) { |
467 | fe->ops->tuner_ops.set_params(fe, param); | 466 | fe->ops.tuner_ops.set_params(fe, param); |
468 | if (fe->ops->i2c_gate_ctrl) fe->ops->i2c_gate_ctrl(fe, 0); | 467 | if (fe->ops.i2c_gate_ctrl) fe->ops.i2c_gate_ctrl(fe, 0); |
469 | } | 468 | } |
470 | 469 | ||
471 | if ((result = nxt6000_set_bandwidth(state, param->u.ofdm.bandwidth)) < 0) | 470 | if ((result = nxt6000_set_bandwidth(state, param->u.ofdm.bandwidth)) < 0) |
@@ -552,13 +551,12 @@ struct dvb_frontend* nxt6000_attach(const struct nxt6000_config* config, | |||
552 | /* setup the state */ | 551 | /* setup the state */ |
553 | state->config = config; | 552 | state->config = config; |
554 | state->i2c = i2c; | 553 | state->i2c = i2c; |
555 | memcpy(&state->ops, &nxt6000_ops, sizeof(struct dvb_frontend_ops)); | ||
556 | 554 | ||
557 | /* check if the demod is there */ | 555 | /* check if the demod is there */ |
558 | if (nxt6000_readreg(state, OFDM_MSC_REV) != NXT6000ASICDEVICE) goto error; | 556 | if (nxt6000_readreg(state, OFDM_MSC_REV) != NXT6000ASICDEVICE) goto error; |
559 | 557 | ||
560 | /* create dvb_frontend */ | 558 | /* create dvb_frontend */ |
561 | state->frontend.ops = &state->ops; | 559 | memcpy(&state->frontend.ops, &nxt6000_ops, sizeof(struct dvb_frontend_ops)); |
562 | state->frontend.demodulator_priv = state; | 560 | state->frontend.demodulator_priv = state; |
563 | return &state->frontend; | 561 | return &state->frontend; |
564 | 562 | ||