]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
V4L/DVB (3863): Convert cx24110 to refactored tuner code
authorAndrew de Quincey <adq_dvb@lidskialf.net>
Tue, 18 Apr 2006 20:47:10 +0000 (17:47 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Sun, 25 Jun 2006 04:58:50 +0000 (01:58 -0300)
Convert to tuner_ops calls.
Remove pll function pointers from structure.
Remove unneeded tuner calls.
Remove unneeded sleep function completely.

Signed-off-by: Andrew de Quincey <adq_dvb@lidskialf.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
drivers/media/dvb/frontends/cx24110.c
drivers/media/dvb/frontends/cx24110.h

index a8d0edd02cda326821e7e9aa8df216900ea3ff05..8d98ffb61e4e44a64a0c23ec3d73eaf6ebfedbed 100644 (file)
@@ -366,17 +366,6 @@ static int cx24110_initfe(struct dvb_frontend* fe)
                cx24110_writereg(state, cx24110_regdata[i].reg, cx24110_regdata[i].data);
        };
 
-       if (state->config->pll_init) state->config->pll_init(fe);
-
-       return 0;
-}
-
-static int cx24110_sleep(struct dvb_frontend *fe)
-{
-       struct cx24110_state *state = fe->demodulator_priv;
-
-       if (state->config->pll_sleep)
-                 return state->config->pll_sleep(fe);
        return 0;
 }
 
@@ -548,7 +537,12 @@ static int cx24110_set_frontend(struct dvb_frontend* fe, struct dvb_frontend_par
 {
        struct cx24110_state *state = fe->demodulator_priv;
 
-       state->config->pll_set(fe, p);
+
+       if (fe->ops->tuner_ops.set_params) {
+               fe->ops->tuner_ops.set_params(fe, p);
+               if (fe->ops->i2c_gate_ctrl) fe->ops->i2c_gate_ctrl(fe, 0);
+       }
+
        cx24110_set_inversion (state, p->inversion);
        cx24110_set_fec (state, p->u.qpsk.fec_inner);
        cx24110_set_symbolrate (state, p->u.qpsk.symbol_rate);
@@ -651,7 +645,6 @@ static struct dvb_frontend_ops cx24110_ops = {
        .release = cx24110_release,
 
        .init = cx24110_initfe,
-       .sleep = cx24110_sleep,
        .set_frontend = cx24110_set_frontend,
        .get_frontend = cx24110_get_frontend,
        .read_status = cx24110_read_status,
index 609ac642b406ad748c791cfd441b825460cb9080..b354a64e0e74970f728d4b5f905a24b5abb3ff75 100644 (file)
@@ -31,11 +31,6 @@ struct cx24110_config
 {
        /* the demodulator's i2c address */
        u8 demod_address;
-
-       /* PLL maintenance */
-       int (*pll_init)(struct dvb_frontend* fe);
-       int (*pll_set)(struct dvb_frontend* fe, struct dvb_frontend_parameters* params);
-       int (*pll_sleep)(struct dvb_frontend* fe);
 };
 
 extern struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,