Commit graph

4 commits

Author SHA1 Message Date
Mauro Carvalho Chehab 7063c1456f [media] r820t: Remove a warning for an unused value
Currently, the driver complains about the pre_detect var:

	drivers/media/tuners/r820t.c: In function 'r820t_sysfreq_sel':
	drivers/media/tuners/r820t.c:722:31: warning: variable 'pre_dect' set but not used [-Wunused-but-set-variable]

While rtl8232 code comments it, perhaps some other driver may use.
So, the better is to keep the code there, allowing to enable it
via r820t config data.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-04-25 16:07:04 -03:00
Mauro Carvalho Chehab d75d538899 [media] r820t: proper initialize the PLL register
The rtl-sdr library, from where this driver was initially
based, doesn't use half PLL clock, but this is used on
the Realtek Kernel driver. So, also do the same here.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Tested-by: Antti Palosaari <crope@iki.fi>
2013-04-16 21:32:27 -03:00
Mauro Carvalho Chehab 84ddc33c20 [media] r820t: add support for diplexer
This is part of the original driver, and adding it doesn't hurt,
so add it, to better sync the code.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Tested-by: Antti Palosaari <crope@iki.fi>
2013-04-16 21:28:31 -03:00
Mauro Carvalho Chehab a80abc58fe [media] r820t: Add a tuner driver for Rafael Micro R820T silicon tuner
This driver was written from scratch, based on an existing driver
that it is part of rtl-sdr git tree, released under GPLv2:
	https://groups.google.com/forum/#!topic/ultra-cheap-sdr/Y3rBEOFtHug
	https://github.com/n1gp/gr-baz
	http://cgit.osmocom.org/rtl-sdr/plain/src/tuner_r820t.c
	(there are also other variants of it out there)
>From what I understood from the threads, the original driver was converted
to userspace from a Realtek tree. I couldn't find the original tree.
However, the original driver look awkward on my eyes. So, I decided to
write a new version from it from the scratch, while trying to reproduce
everything found there.
TODO:
- After locking, the original driver seems to have some routines to
  improve reception. This was not implemented here yet.
- RF Gain set/get is not implemented.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Tested-by: Antti Palosaari <crope@iki.fi>
2013-04-16 21:18:42 -03:00