aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/dvb/frontends/tda18271-fe.c
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2007-12-02 11:03:57 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 19:03:13 -0200
commitaaeccba68a60eedee5fe90f9e1478367b1f97345 (patch)
tree02f840507d66d23fa9210eefe3993423b58159bd /drivers/media/dvb/frontends/tda18271-fe.c
parent293da0ec468addf891856e9ffee88af2fd00e25a (diff)
V4L/DVB (6726): tda18271: set image rejection validity
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/dvb/frontends/tda18271-fe.c')
-rw-r--r--drivers/media/dvb/frontends/tda18271-fe.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/media/dvb/frontends/tda18271-fe.c b/drivers/media/dvb/frontends/tda18271-fe.c
index 01de75e369e..fee38c1657e 100644
--- a/drivers/media/dvb/frontends/tda18271-fe.c
+++ b/drivers/media/dvb/frontends/tda18271-fe.c
@@ -578,7 +578,16 @@ static int tda18271_tune(struct dvb_frontend *fe,
regs[R_EP4] &= ~0x80; /* turn this bit on only for fm */
- /* FIXME: image rejection validity EP5[2:0] */
+ /* image rejection validity EP5[2:0] */
+ i = 0;
+ while ((tda18271_ir_measure[i].rfmax * 1000) < freq) {
+ if (tda18271_ir_measure[i].rfmax == 0)
+ break;
+ i++;
+ }
+ dbg_map("ir measure, i = %d\n", i);
+ regs[R_EP5] &= ~0x07;
+ regs[R_EP5] |= tda18271_ir_measure[i].val;
/* calculate MAIN PLL */
N = freq + ifc;