diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-12-23 05:01:06 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-12-31 05:37:56 -0500 |
commit | 742905312a5bfb67d3efe5f5fcb1a993b8f784b2 (patch) | |
tree | 1f8b7eff73edb7e7410dfd8357acc474d0ede4e6 /drivers/media/dvb/mantis | |
parent | 93ce675c5cc57cac37e32953fdd43179e02f5c54 (diff) |
[media] mantis_vp1033: 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>
Diffstat (limited to 'drivers/media/dvb/mantis')
-rw-r--r-- | drivers/media/dvb/mantis/mantis_vp1033.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/dvb/mantis/mantis_vp1033.c b/drivers/media/dvb/mantis/mantis_vp1033.c index 2ae0afa7756b..dfaca2ab4803 100644 --- a/drivers/media/dvb/mantis/mantis_vp1033.c +++ b/drivers/media/dvb/mantis/mantis_vp1033.c | |||
@@ -86,6 +86,7 @@ u8 lgtdqcs001f_inittab[] = { | |||
86 | int lgtdqcs001f_tuner_set(struct dvb_frontend *fe, | 86 | int lgtdqcs001f_tuner_set(struct dvb_frontend *fe, |
87 | struct dvb_frontend_parameters *params) | 87 | struct dvb_frontend_parameters *params) |
88 | { | 88 | { |
89 | struct dtv_frontend_properties *p = &fe->dtv_property_cache; | ||
89 | struct mantis_pci *mantis = fe->dvb->priv; | 90 | struct mantis_pci *mantis = fe->dvb->priv; |
90 | struct i2c_adapter *adapter = &mantis->adapter; | 91 | struct i2c_adapter *adapter = &mantis->adapter; |
91 | 92 | ||
@@ -95,14 +96,14 @@ int lgtdqcs001f_tuner_set(struct dvb_frontend *fe, | |||
95 | 96 | ||
96 | struct i2c_msg msg = {.addr = 0x61, .flags = 0, .buf = buf, .len = sizeof(buf)}; | 97 | struct i2c_msg msg = {.addr = 0x61, .flags = 0, .buf = buf, .len = sizeof(buf)}; |
97 | 98 | ||
98 | div = params->frequency / 250; | 99 | div = p->frequency / 250; |
99 | 100 | ||
100 | buf[0] = (div >> 8) & 0x7f; | 101 | buf[0] = (div >> 8) & 0x7f; |
101 | buf[1] = div & 0xff; | 102 | buf[1] = div & 0xff; |
102 | buf[2] = 0x83; | 103 | buf[2] = 0x83; |
103 | buf[3] = 0xc0; | 104 | buf[3] = 0xc0; |
104 | 105 | ||
105 | if (params->frequency < 1531000) | 106 | if (p->frequency < 1531000) |
106 | buf[3] |= 0x04; | 107 | buf[3] |= 0x04; |
107 | else | 108 | else |
108 | buf[3] &= ~0x04; | 109 | buf[3] &= ~0x04; |