diff options
author | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-03-03 16:27:38 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-03-04 14:43:43 -0300 |
commit | 6cff36b23b66f437be904407601117fc74071db3 (patch) | |
tree | efe63f613f9d3104990a1642502eef11c3d37aac /drivers/media/tuners | |
parent | 4fd3281a4164d88ab20910b59b4f11cdd3f3216e (diff) | |
download | op-kernel-dev-6cff36b23b66f437be904407601117fc74071db3.zip op-kernel-dev-6cff36b23b66f437be904407601117fc74071db3.tar.gz |
[media] tda18212: add support for ATSC and clearQAM on tda18272
tda18272 is programmed just like tda18212, but it also
supports ClearQAM and ATSC.
Add support for them. Tested with a Kworld UB435-Q on both
8VSB and 256QAM modes.
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/tuners')
-rw-r--r-- | drivers/media/tuners/tda18212.c | 12 | ||||
-rw-r--r-- | drivers/media/tuners/tda18212.h | 2 |
2 files changed, 14 insertions, 0 deletions
diff --git a/drivers/media/tuners/tda18212.c b/drivers/media/tuners/tda18212.c index abe256e..05a4ac9 100644 --- a/drivers/media/tuners/tda18212.c +++ b/drivers/media/tuners/tda18212.c @@ -150,6 +150,8 @@ static int tda18212_set_params(struct dvb_frontend *fe) #define DVBT2_8 5 #define DVBC_6 6 #define DVBC_8 7 + #define ATSC_VSB 8 + #define ATSC_QAM 9 static const u8 bw_params[][3] = { /* reg: 0f 13 23 */ [DVBT_6] = { 0xb3, 0x20, 0x03 }, @@ -160,6 +162,8 @@ static int tda18212_set_params(struct dvb_frontend *fe) [DVBT2_8] = { 0xbc, 0x22, 0x01 }, [DVBC_6] = { 0x92, 0x50, 0x03 }, [DVBC_8] = { 0x92, 0x53, 0x03 }, + [ATSC_VSB] = { 0x7d, 0x20, 0x63 }, + [ATSC_QAM] = { 0x7d, 0x20, 0x63 }, }; dev_dbg(&priv->i2c->dev, @@ -171,6 +175,14 @@ static int tda18212_set_params(struct dvb_frontend *fe) fe->ops.i2c_gate_ctrl(fe, 1); /* open I2C-gate */ switch (c->delivery_system) { + case SYS_ATSC: + if_khz = priv->cfg->if_atsc_vsb; + i = ATSC_VSB; + break; + case SYS_DVBC_ANNEX_B: + if_khz = priv->cfg->if_atsc_qam; + i = ATSC_QAM; + break; case SYS_DVBT: switch (c->bandwidth_hz) { case 6000000: diff --git a/drivers/media/tuners/tda18212.h b/drivers/media/tuners/tda18212.h index 7e0d503..c36b49e 100644 --- a/drivers/media/tuners/tda18212.h +++ b/drivers/media/tuners/tda18212.h @@ -35,6 +35,8 @@ struct tda18212_config { u16 if_dvbt2_7; u16 if_dvbt2_8; u16 if_dvbc; + u16 if_atsc_vsb; + u16 if_atsc_qam; }; #if IS_ENABLED(CONFIG_MEDIA_TUNER_TDA18212) |