diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-12-23 10:33:05 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-12-31 05:33:19 -0500 |
commit | b738ae160a9991d133671873f68c2ccffe524d12 (patch) | |
tree | 68e6d714e9bedfde3a143e4b44b0d2ee53d91c33 | |
parent | b09cf61dfe444810bbcf0b247a81146d4ef07218 (diff) |
[media] cx88: use DVBv5 parameters on set_params()
Instead of using DVBv3 parameters, rely on DVBv5 parameters to
set the tuner
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/video/cx88/cx88-dvb.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/video/cx88/cx88-dvb.c b/drivers/media/video/cx88/cx88-dvb.c index 396149824fcd..f5430772d504 100644 --- a/drivers/media/video/cx88/cx88-dvb.c +++ b/drivers/media/video/cx88/cx88-dvb.c | |||
@@ -818,6 +818,7 @@ static const u8 samsung_smt_7020_inittab[] = { | |||
818 | static int samsung_smt_7020_tuner_set_params(struct dvb_frontend *fe, | 818 | static int samsung_smt_7020_tuner_set_params(struct dvb_frontend *fe, |
819 | struct dvb_frontend_parameters *params) | 819 | struct dvb_frontend_parameters *params) |
820 | { | 820 | { |
821 | struct dtv_frontend_properties *c = &fe->dtv_property_cache; | ||
821 | struct cx8802_dev *dev = fe->dvb->priv; | 822 | struct cx8802_dev *dev = fe->dvb->priv; |
822 | u8 buf[4]; | 823 | u8 buf[4]; |
823 | u32 div; | 824 | u32 div; |
@@ -827,14 +828,14 @@ static int samsung_smt_7020_tuner_set_params(struct dvb_frontend *fe, | |||
827 | .buf = buf, | 828 | .buf = buf, |
828 | .len = sizeof(buf) }; | 829 | .len = sizeof(buf) }; |
829 | 830 | ||
830 | div = params->frequency / 125; | 831 | div = c->frequency / 125; |
831 | 832 | ||
832 | buf[0] = (div >> 8) & 0x7f; | 833 | buf[0] = (div >> 8) & 0x7f; |
833 | buf[1] = div & 0xff; | 834 | buf[1] = div & 0xff; |
834 | buf[2] = 0x84; /* 0xC4 */ | 835 | buf[2] = 0x84; /* 0xC4 */ |
835 | buf[3] = 0x00; | 836 | buf[3] = 0x00; |
836 | 837 | ||
837 | if (params->frequency < 1500000) | 838 | if (c->frequency < 1500000) |
838 | buf[3] |= 0x10; | 839 | buf[3] |= 0x10; |
839 | 840 | ||
840 | if (fe->ops.i2c_gate_ctrl) | 841 | if (fe->ops.i2c_gate_ctrl) |