dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

22 Commits

Author SHA1 Message Date
Mauro Carvalho Chehab 7581e61d8d [media] dvb: Remove ops->info.type from frontends
Now that this field is deprecated, and core generates it for
DVBv3 calls, remove it from the drivers.

It also adds .delsys on the few drivers where this were missed.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-01-04 17:30:34 -02:00
Mauro Carvalho Chehab 7c61d80a9b [media] dvb: don't require a parameter for get_frontend
Just like set_frontend, use the dvb cache properties for get_frontend.
This is more consistent, as both functions are now symetric. Also,
at the places get_frontend is called, it makes sense to update the
cache.

Most of this patch were generated by this small perl script:

	while (<>) { $file .= $_; }
	if ($file =~ m/\.get_frontend\s*=\s*([\d\w_]+)/) {
		my $get = $1;
		$file =~ s/($get)(\s*\([^\,\)]+)\,\s*struct\s+dtv_frontend_properties\s*\*\s*([_\d\w]+)\)\s*\{/\1\2)\n{\n\tstruct dtv_frontend_properties *\3 = &fe->dtv_property_cache;/g;
	}
	print $file;

Of course, the changes at dvb_frontend.[ch] were made by hand,
as well as the changes on a few other places, where get_frontend()
is called internally inside the driver.

On some places, get_frontend() were just a void function. Those
occurrences were removed, as the DVB core handles such cases.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-31 10:28:23 -02:00
Mauro Carvalho Chehab 102a820d36 [media] s55h1411: convert set_fontend to use DVBv5 parameters
Instead of using dvb_frontend_parameters struct, that were
designed for a subset of the supported standards, use the DVBv5
cache information.

Also, fill the supported delivery systems at dvb_frontend_ops
struct.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-31 09:47:32 -02:00
Mauro Carvalho Chehab a689e3657d [media] dvb-core: add support for a DVBv5 get_frontend() callback
Creates a DVBv5 get_frontend call, renaming the DVBv3 one to
get_frontend_legacy(), while not all frontends are converted.

After the conversion for all drivers, get_frontend_legacy()
will be removed.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-31 09:10:49 -02:00
Mauro Carvalho Chehab bc9cd2736b [media] Rename set_frontend fops to set_frontend_legacy
Passing DVBv3 parameters to set_frontend is not fun, as the
core doesn't have any way to know if the driver is using the
v3 or v5 parameters. So, rename the callback and add a new
one to allow distinguish between a mixed v3/v5 paramenter call
from a pure v5 call.

After having all frontends to use the new way, the legacy
call can be removed.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-31 09:09:43 -02:00
Mauro Carvalho Chehab 14d24d148c [media] tuners: remove dvb_frontend_parameters from set_params()
This is a big patch, yet trivial: now that all tuners use the DVBv5
way to pass parameters (e. g. via fe->dtv_property_cache), the
extra parameter can be removed from set_params() call.

After this change, very few DVBv3 specific stuff are left at the
tuners.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-31 08:57:29 -02:00
Michael Krufky ead32d5357 [media] s5h1411: Calculate signal strength shown as percentage from SNR up to 35dB
As done first in lgdt330x.c, calculate signal strength from SNR up to 35dB
Even though the SNR can go higher than 35dB, there is some comfort factor
in having a range of strong signals that can show at 100%

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-11-07 13:20:17 -02:00
Matthias Schwarzott 084e24acc9 V4L/DVB (12440): Use kzalloc for frontend states to have struct dvb_frontend properly
This patch changes most frontend drivers to allocate their state structure via
kzalloc and not kmalloc. This is done to properly initialize the
embedded "struct dvb_frontend frontend" field, that they all have.

The visible effect of this struct being uninitalized is, that the member "id"
that is used to set the name of kernel thread is totally random.

Some board drivers (for example cx88-dvb) set this "id" via
videobuf_dvb_alloc_frontend but most do not.

So I at least get random id values for saa7134, flexcop and ttpci based cards.
It looks like this in dmesg:
DVB: registering adapter 1 frontend -10551321 (ST STV0299 DVB-S)

The related kernel thread then also gets a strange name
like "kdvb-ad-1-fe--1".

Cc: Michael Krufky <mkrufky@linuxtv.org>
Cc: Steven Toth <stoth@linuxtv.org>
Cc: Timothy Lee <timothy.lee@siriushk.com>
Cc: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Matthias Schwarzott <zzam@gentoo.org>
Acked-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-13 20:39:14 -03:00
Devin Heitmueller 726cf2000b V4L/DVB (9633): Put s5h1411 into low power mode at end of attach() call
Place the s5h1411 into low power mode until first use (to handle the case where
the user plugs in the device and then doesn't use it for a while).  On the
Pinnacle 801e, this brings the power usage from 126ma down to 82ma.

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-12-29 17:53:34 -02:00
Devin Heitmueller 11fc9a4a44 V4L/DVB (9316): s5h1411: Power down s5h1411 when not in use
Power down the s5h1411 demodulator when not in use (on the Pinnacle 801e, this
brings idle power from 123ma down to 84ma).

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Acked-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:31:06 -02:00
Devin Heitmueller 50eac6bc46 V4L/DVB (9315): s5h1411: Skip reconfiguring demod modulation if already at the desired modulation
If we are already at the desired modulation, there is no need to reconfigure
the demod (at a tuning time cost)

Note that this change revealed that although the datasheet says the demod
starts out in VSB-8 mode, the first tuning was failing consistently unless
we went through the work of setting the registers.  So add a field to denote
this case so we always do the enable_frontend call, even if the first tuning
request is for VSB-8.

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Reviewed-by: Michael Krufky <mkrufky@linuxtv.org>
Acked-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:31:04 -02:00
Devin Heitmueller f0d041e50b V4L/DVB (9314): s5h1411: Perform s5h1411 soft reset after tuning
If you instruct the tuner to change frequencies, it can take up to 2500ms to
get a demod lock.  By performing a soft reset after the tuning call (which
is consistent with how the Pinnacle 801e Windows driver behaves), you get
a demod lock inside of 300ms

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Reviewed-by: Michael Krufky <mkrufky@linuxtv.org>
Acked-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:31:01 -02:00
Steven Toth 5bd47311fe V4L/DVB (9312): s5h1411: Remove meaningless code
s5h1411: Remove meaningless code

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:30:55 -02:00
Steven Toth 1af46b450f V4L/DVB (9311): s5h1411: bugfix: Setting serial or parallel mode could destroy bits
Adding a serialmode function to read/and/or/write the register for safety.

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:30:51 -02:00
Steven Toth e16c63de92 V4L/DVB (9310): s5h1411: read_status() locking detection fixes.
This includes new bit definitions for previously unknown bits.

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:30:48 -02:00
Steven Toth c96de5197d V4L/DVB (9309): s5h1411: I/F related bugfix for 3.25 and remove spurious define
This should improve performance.

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:30:43 -02:00
Steven Toth f4ef033ee0 V4L/DVB (9308): s5h1411: Improvements to the default registers
s5h1411: Improvements to the default registers

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-21 14:30:36 -02:00
Steven Toth b431c61642 V4L/DVB (9259): s5h1411: Checkpatch compliance
s5h1411: Checkpatch compliance

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-10-17 17:27:52 -03:00
Steven Toth 6d8976164d V4L/DVB (8805): Steven Toth email address change
I need this so I can better isolate my linux email from my
corporate email.

Signed-off-by: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-09-03 18:37:21 -03:00
Steven Toth 5ca947a999 V4L/DVB (8804): s5h1411: Enable QAM_AUTO mode
If apps pass QAM_AUTO then we need to obey it.

Signed-off-by: Steven Toth <stoth@hauppauge.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-09-03 18:37:20 -03:00
Michael Krufky 54b6550e43 V4L/DVB (7921): s5h1411.c shouldn't #include "dvb-pll.h"
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-20 07:06:32 -03:00
Steven Toth 8b4f1d0316 V4L/DVB (7741): s5h1411: Adding support for this ATSC/QAM demodulator
This adds full support for this demodulator.

Signed-off-by: Steven Toth <stoth@hauppauge.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-04-26 09:29:56 -03:00