summaryrefslogtreecommitdiff
path: root/drivers/media/tuners/m88ts2022.c
AgeCommit message (Collapse)Author
2015-04-02[media] m88ts2022: remove obsolete driverAntti Palosaari
This driver was replaced by ts2020 driver. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-04-02[media] m88ts2022: Nested loops shouldn't use the same index variableDavid Howells
There are a pair of nested loops inside m88ts2022_cmd() that use the same index variable, but for different things. Split the variable. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2014-11-03[media] m88ts2022: return the err code in its probe function when error occursnibble.max
if "chip_id" is wrong or "dev->cfg.clock_out" is invalid, the i2c model is still loaded. It will cause "kernel NULL pointer dereference" oops when the i2c model remove. returning the err code will prevent the i2c model load. Signed-off-by: Nibble Max <nibble.max@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2014-09-08[media] m88ts2022: change parameter type of m88ts2022_cmdAntti Palosaari
It is driver internal function and does not need anything from frontend structure. Due to that change parameter type to driver state which is better for driver internal functions. Also remove one unused variable from state itself. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2014-09-08[media] m88ts2022: convert to RegMap I2C APIAntti Palosaari
Use RegMap to cover I2C register routines. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2014-09-08[media] m88ts2022: clean up loggingAntti Palosaari
There is no need to print module name nor function name as those are done by kernel logging system when dev_xxx logging is used and driver is proper I2C driver. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2014-09-08[media] m88ts2022: rename device state (priv => dev)Antti Palosaari
foo_dev seems to be most correct term for the structure holding data of each device instance. It is most used term in Kernel and also examples from book Linux Device Drivers, Third Edition, uses it. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2014-09-02[media] m88ts2022: fix coding style issuesAntti Palosaari
Fix coding style issues pointed out by checkpatch.pl. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2014-09-02[media] m88ts2022: fix 32bit overflow on filter calcAntti Palosaari
Maximum satellite symbol rate used is 45000000Sps which overflows when multiplied by 135. As final calculation result is fraction, we could use mult_frac macro in order to keep calculation inside 32 bit number limits and prevent overflow. Original bug and fix was provided by Nibble Max. I decided to implement it differently as it is now. Reported-by: Nibble Max <nibble.max@gmail.com> Tested-by: Nibble Max <nibble.max@gmail.com> Cc: <stable@kernel.org> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-19[media] m88ts2022: fix some style issues reported by checkpatch.plAntti Palosaari
Latest checkpatch.pl has some new requirements for coding style. Fix some of those. * remove Free Software Foundation postal address * use sizeof(*foo), not sizeof(struct foo) Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-19[media] m88ts2022: convert to Kernel I2C driver modelAntti Palosaari
Convert driver from proprietary DVB driver model to standard I2C driver model. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-19[media] m88ts2022: reimplement synthesizer calculationsAntti Palosaari
Used synthesizer is very typical integer-N PLL, with configurable reference frequency divider, output frequency divider and of course N itself. Most common method to calculate values is first select output divider, then calculate VCO frequency and finally calculate PLL N from VCO frequency. Do it that way. Also make some cleanups for filter logic and signal strength. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-19[media] m88ts2022: do not use dynamic stack allocationAntti Palosaari
I2C transfer were using dynamic stack allocation. Get rid of it. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-19[media] Montage M88TS2022 silicon tuner driverAntti Palosaari
M88TS2022 is DVB-S/S2 RF tuner used usually in conjunction with Montage M88DS3103 DVB-S/S2 demodulator. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>