From 71b1e82794bbae7b23409e013f7249dd2f382160 Mon Sep 17 00:00:00 2001 From: Antti Palosaari Date: Sun, 9 Dec 2012 00:30:08 -0300 Subject: [media] fc0012: add RF loop through Signed-off-by: Antti Palosaari Acked-by: Hans-Frieder Vogt Signed-off-by: Mauro Carvalho Chehab --- drivers/media/tuners/fc0012.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'drivers/media/tuners/fc0012.c') diff --git a/drivers/media/tuners/fc0012.c b/drivers/media/tuners/fc0012.c index 5ede0c049bc0..636f951219db 100644 --- a/drivers/media/tuners/fc0012.c +++ b/drivers/media/tuners/fc0012.c @@ -101,6 +101,9 @@ static int fc0012_init(struct dvb_frontend *fe) if (priv->dual_master) reg[0x0c] |= 0x02; + if (priv->cfg->loop_through) + reg[0x09] |= 0x01; + if (fe->ops.i2c_gate_ctrl) fe->ops.i2c_gate_ctrl(fe, 1); /* open I2C-gate */ @@ -445,6 +448,7 @@ struct dvb_frontend *fc0012_attach(struct dvb_frontend *fe, return NULL; priv->i2c = i2c; + priv->cfg = cfg; priv->dual_master = cfg->dual_master; priv->addr = cfg->i2c_address; priv->xtal_freq = cfg->xtal_freq; @@ -453,6 +457,9 @@ struct dvb_frontend *fc0012_attach(struct dvb_frontend *fe, fe->tuner_priv = priv; + if (priv->cfg->loop_through) + fc0012_writereg(priv, 0x09, 0x6f); + memcpy(&fe->ops.tuner_ops, &fc0012_tuner_ops, sizeof(struct dvb_tuner_ops)); -- cgit v1.2.1