diff options
author | Manu Abraham <manu@linuxtv.org> | 2009-04-07 12:19:54 +0400 |
---|---|---|
committer | Manu Abraham <manu@linuxtv.org> | 2009-04-07 12:19:54 +0400 |
commit | 028d9a0c9dfc2039314063233c47fef4905d9071 (patch) | |
tree | a380c6f58f4e7f2b9bc1cd08150158b2a8c797b8 /linux/drivers/media/dvb/frontends/stv090x.c | |
parent | bd6cdb0ea9b6db322a484ad00da53cdd7307fc43 (diff) | |
download | mediapointer-dvb-s2-028d9a0c9dfc2039314063233c47fef4905d9071.tar.gz mediapointer-dvb-s2-028d9a0c9dfc2039314063233c47fef4905d9071.tar.bz2 |
* Reference clock was unused
* Fix missing repeater level setup
From: Manu Abraham <abraham.manu@gmail.com>
Signed-off-by: Manu Abraham <manu@linuxtv.org>
Diffstat (limited to 'linux/drivers/media/dvb/frontends/stv090x.c')
-rw-r--r-- | linux/drivers/media/dvb/frontends/stv090x.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/linux/drivers/media/dvb/frontends/stv090x.c b/linux/drivers/media/dvb/frontends/stv090x.c index fc0781961..7d6cb0600 100644 --- a/linux/drivers/media/dvb/frontends/stv090x.c +++ b/linux/drivers/media/dvb/frontends/stv090x.c @@ -1484,16 +1484,19 @@ static int stv090x_write_reg(struct stv090x_state *state, unsigned int reg, u8 d static int stv090x_i2c_gate_ctrl(struct dvb_frontend *fe, int enable) { struct stv090x_state *state = fe->demodulator_priv; + const struct stv090x_config *config = state->config; u32 reg; reg = STV090x_READ_DEMOD(state, I2CRPT); - +// STV090x_SETFIELD_Px(reg, ENARPT_LEVEL_FIELD, config->repeater_level); if (enable) { + dprintk(FE_DEBUG, 1, "Enable Gate"); STV090x_SETFIELD_Px(reg, I2CT_ON_FIELD, 1); if (STV090x_WRITE_DEMOD(state, I2CRPT, reg) < 0) goto err; } else { + dprintk(FE_DEBUG, 1, "Disable Gate"); STV090x_SETFIELD_Px(reg, I2CT_ON_FIELD, 0); if ((STV090x_WRITE_DEMOD(state, I2CRPT, reg)) < 0) goto err; @@ -4629,6 +4632,7 @@ static int stv090x_setup(struct dvb_frontend *fe) const struct stv090x_reg *stv090x_initval = NULL; const struct stv090x_reg *stv090x_cut20_val = NULL; unsigned long t1_size = 0, t2_size = 0; + u32 reg = 0; int i; @@ -4668,7 +4672,8 @@ static int stv090x_setup(struct dvb_frontend *fe) if (STV090x_WRITE_DEMOD(state, TNRCFG, 0x6c) < 0) /* check register ! (No Tuner Mode) */ goto err; - if (STV090x_WRITE_DEMOD(state, I2CRPT, 0x00) < 0) /* repeater OFF */ + STV090x_SETFIELD_Px(reg, ENARPT_LEVEL_FIELD, config->repeater_level); + if (STV090x_WRITE_DEMOD(state, I2CRPT, reg) < 0) /* repeater OFF */ goto err; if (stv090x_write_reg(state, STV090x_NCOARSE, 0x13) < 0) /* set PLL divider */ |