]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/log
mirror_ubuntu-eoan-kernel.git
15 years agoV4L/DVB (9725): cx18: Remove unnecessary MMIO accesses in time critical irq handling...
Andy Walls [Tue, 18 Nov 2008 01:48:46 +0000 (22:48 -0300)]
V4L/DVB (9725): cx18: Remove unnecessary MMIO accesses in time critical irq handling path

Remove unnecessary MMIO accesses in time critical irq handling path.  Also
ensured that the mailbox ack field is read in last, so we know for sure if we
have a stale mailbox or not on receipt.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9724): cx18: Streamline cx18-io[ch] wrappers and enforce MMIO retry strategy
Andy Walls [Mon, 17 Nov 2008 02:33:41 +0000 (23:33 -0300)]
V4L/DVB (9724): cx18: Streamline cx18-io[ch] wrappers and enforce MMIO retry strategy

cx18: Streamline cx18-io[ch] wrappers and enforce MMIO retry strategy so that
write retries always occur and read retries never occur (as they never help).
Remove MMIO statistics logging to speed up MMIO accesses.  Deprecate & ignore
retry_mmio and mmio_ndelay module parameters, to essentially force
retry_mmio=1 and mmio_ndelay=0.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9723): cx18: Propagate staleness of mailbox and mdl ack data to work handler
Andy Walls [Mon, 17 Nov 2008 00:18:00 +0000 (21:18 -0300)]
V4L/DVB (9723): cx18: Propagate staleness of mailbox and mdl ack data to work handler

cx18: Propagate staleness of mailbox and mdl ack data to work handler to let
the work handler know that the data from the encoder may not be coherent.
Allows for smarter handling of buffers in future, to deal with MDLs that fall
out of rotation due to irq handler being late in collecting mailbox and mdl ack
info.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9722): cx18: Convert per stream queue spinlocks into mutexes
Andy Walls [Sun, 16 Nov 2008 23:18:05 +0000 (20:18 -0300)]
V4L/DVB (9722): cx18: Convert per stream queue spinlocks into mutexes

Convert the per stream queue spinlocks into mutexes.  All queue
manipulation happens via the work queue or system calls into the driver, and
not in an interrupt context.  This reduces the amout of time the cx18 driver
keeps interrupts disabled.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9721): cx18: Change to singlethreaded global work queue thread for deferable...
Andy Walls [Sun, 16 Nov 2008 20:15:01 +0000 (17:15 -0300)]
V4L/DVB (9721): cx18: Change to singlethreaded global work queue thread for deferable work

Change to singlethreaded global work queue thread for deferable work,
instead of the kernel default multithreaded work queue.  This ensures
execution of deferable work is always in the proper order, so caputred buffers
don't get reordered.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9720): cx18: Major rewrite of interrupt handling for incoming mailbox processing
Andy Walls [Sun, 16 Nov 2008 04:38:19 +0000 (01:38 -0300)]
V4L/DVB (9720): cx18: Major rewrite of interrupt handling for incoming mailbox processing

A major rewrite of interrupt handling for incoming mailbox processing, to split
the timing critical steps from the the deferrable steps as the sending XPU on
the CX23418 will time out and overwrite our incoming mailboxes rather quickly.
Setup a pool of work "order forms" for the irq handler to send jobs to the new
work handler routine which uses the kernel default work queue to do the
deferrable work.  Started optimizing some of the cx18-io calls as they are now
the low hanging fruit for recoving microseconds back from the timeline.
Future optimizations will get rid of mmio read retries, mmio stats logging, and
combine smaller functions in the irq path into the larger ones to save ~2 us
each.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9710): gspca: Remove some unuseful core in main.
Jean-Francois Moine [Sat, 22 Nov 2008 07:27:34 +0000 (04:27 -0300)]
V4L/DVB (9710): gspca: Remove some unuseful core in main.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9707): gspca: Remove the event counter and simplify the frame wait.
Hans de Goede [Wed, 19 Nov 2008 20:16:26 +0000 (17:16 -0300)]
V4L/DVB (9707): gspca: Remove the event counter and simplify the frame wait.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9655): radio-mr800: fix unplug
Alexey Klimov [Wed, 19 Nov 2008 03:36:29 +0000 (00:36 -0300)]
V4L/DVB (9655): radio-mr800: fix unplug

This patch fixes problems(kernel oopses) with unplug of device while
it's working.
Patch adds disconnect_lock mutex, changes usb_amradio_close and
usb_amradio_disconnect functions and adds a lot of safety checks.

Signed-off-by: Alexey Klimov <klimov.linux@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9599): cx18: Fix unitialized variable problem upon APU firmware file read...
Andy Walls [Sun, 9 Nov 2008 22:51:44 +0000 (19:51 -0300)]
V4L/DVB (9599): cx18: Fix unitialized variable problem upon APU firmware file read failure

If APU firmware file read failed, the jump vector to the APU was undefined and
the APU would be started executing garbage.  Fix uninitialized variable to be
an infinite loop for the APU, but also bail out before even starting the APU.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9598): cx18: Prevent CX23418 from clearing it's outgoing ack interrupts...
Andy Walls [Sun, 9 Nov 2008 21:14:07 +0000 (18:14 -0300)]
V4L/DVB (9598): cx18: Prevent CX23418 from clearing it's outgoing ack interrupts to driver

When the CX23418 CPU unit sent out an ack interrupt to the linux driver, it
also received that interrupt and cleared the flag before the linux driver could
see what the interrupt was for.  This fix prevents the CPU from receiving an
IRQ for it's own outgoing ack's to the linux driver.  This fix is critical now
that the linux driver doesn't poll but relies on these ack interrupts.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9597): cx18: Minor fixes to APU firmware load process
Andy Walls [Sat, 8 Nov 2008 20:14:22 +0000 (17:14 -0300)]
V4L/DVB (9597): cx18: Minor fixes to APU firmware load process

Use the APU fw start address from rom file instead of a hardcoded entry vector.
Fixed cx18_setup_page() calls to use the correct APU image load addresses.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9596): cx18: Further changes to improve mailbox protocol integrity & performnce
Andy Walls [Sat, 8 Nov 2008 17:19:37 +0000 (14:19 -0300)]
V4L/DVB (9596): cx18: Further changes to improve mailbox protocol integrity & performnce

All waits for cx18 mailbox API commands are now uninterruptable.  Added
code to collect mailbox ack statistics.  Tweaked timeouts based on collected
stats and video vertical frame and field rates.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9595): cx18: Improve handling of outgoing mailboxes detected to be busy
Andy Walls [Sat, 8 Nov 2008 02:57:46 +0000 (23:57 -0300)]
V4L/DVB (9595): cx18: Improve handling of outgoing mailboxes detected to be busy

cx18: Improve handling of outgoing mailboxes detected to be busy.  When
encountering a busy mailbox, sleep instead of polling, and wait for interrupt or
timeout.  If the mailbox is still busy, force it free.  When sending commands,
make sure we never create a situation where we mark the mailbox busy upon
sending, and ensure we always have a method to cleanly recover from a busy
mailbox.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9594): cx18: Roll driver version number due to significant changes
Andy Walls [Thu, 6 Nov 2008 04:33:27 +0000 (01:33 -0300)]
V4L/DVB (9594): cx18: Roll driver version number due to significant changes

Driver interrupt and mailbox handling has change significantly.
Time for a roll to v1.0.2.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9593): cx18: Add outgoing mailbox mutexes and check for ack via waitq vs...
Andy Walls [Thu, 6 Nov 2008 04:15:41 +0000 (01:15 -0300)]
V4L/DVB (9593): cx18: Add outgoing mailbox mutexes and check for ack via waitq vs poll

Add mutexes to ensure exclusive access for outgoing driver to CX23418 mailboxes.
Also wait on a waitq for mailbox acknowledgement from the CX23418 instead of
polling.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9592): cx18: Use default kernel work queue; fix streaming flag for work...
Andy Walls [Thu, 6 Nov 2008 00:19:15 +0000 (21:19 -0300)]
V4L/DVB (9592): cx18: Use default kernel work queue; fix streaming flag for work handler

cx18: Use default kernel work queue; fix streaming flag for work handler.
Eliminate cx18 specific work queue and use the kernel default work queue.
Fixed the F_STREAMING_FLAG for the TS stream so cx18_dvb_work_handler()
can know when it is not safe to send MDLs to the firmware.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9558): gspca: Add the light frequency control for the sensor HV7131B in...
Jean-Francois Moine [Thu, 6 Nov 2008 18:35:21 +0000 (15:35 -0300)]
V4L/DVB (9558): gspca: Add the light frequency control for the sensor HV7131B in zc3xx

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9513): cx18: Reduce number of mmio read retries
Andy Walls [Sun, 2 Nov 2008 21:15:28 +0000 (18:15 -0300)]
V4L/DVB (9513): cx18: Reduce number of mmio read retries

cx18: Reduce number of mmio read retries to improve performance.  Experiments
have shown 2 things: read retries never improve the result of a suspect mmio
read from the CX23418 (the result stays all 0xff's), and that most of the
suspected read failures are actually proper reads of values that should be
all 0xff's.  This change reduces the number of read retries and keeps the
count separate from write retries.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9442): Revert back previous change to 90MHz
Manu Abraham [Mon, 19 Nov 2007 19:44:47 +0000 (16:44 -0300)]
V4L/DVB (9442): Revert back previous change to 90MHz

Note:
* At High Symbol Rates we do not have enouph machine cycles to handle the
  incoming symbols and hence might run into problems at the very end of the
  specified definition
* Most of the equations have been calculated for a master clock of 99 MHz,
  running at 90MHz, raises lot of issues such as the need to recalculate
  all of them , which is eventually very painful.

Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9431): Bug ID #19: Diseqc works properly at 90MHz only on Cut 1.1 and 2.0
Manu Abraham [Tue, 30 Oct 2007 12:31:13 +0000 (09:31 -0300)]
V4L/DVB (9431): Bug ID #19: Diseqc works properly at 90MHz only on Cut 1.1 and 2.0

Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9425): Initialize at 90MHz itself
Manu Abraham [Thu, 18 Oct 2007 09:25:51 +0000 (06:25 -0300)]
V4L/DVB (9425): Initialize at 90MHz itself

Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9767): em28xx: improve board description messages
Mauro Carvalho Chehab [Sat, 29 Nov 2008 02:46:43 +0000 (23:46 -0300)]
V4L/DVB (9767): em28xx: improve board description messages

Print manufacturer/product info from USB device and also card entry.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9766): em28xx: improve probe messages
Mauro Carvalho Chehab [Thu, 27 Nov 2008 17:32:17 +0000 (14:32 -0300)]
V4L/DVB (9766): em28xx: improve probe messages

Prints usb speed used by em28xx interface. While there, fixes USB ID's
endiannes.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9765): em28xx: move tuner gpio's to the cards struct
Mauro Carvalho Chehab [Thu, 27 Nov 2008 12:21:55 +0000 (09:21 -0300)]
V4L/DVB (9765): em28xx: move tuner gpio's to the cards struct

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9764): em28xx: Add support for suspend the device when not used
Mauro Carvalho Chehab [Thu, 27 Nov 2008 12:10:40 +0000 (09:10 -0300)]
V4L/DVB (9764): em28xx: Add support for suspend the device when not used

Several chips may be turned off when the device is not used, like audio,
video and dvb demods. This patch adds a gpio callback at the core
structs to allow turning off such devices.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9763): em28xx: fix gpio settings
Mauro Carvalho Chehab [Thu, 27 Nov 2008 12:00:00 +0000 (09:00 -0300)]
V4L/DVB (9763): em28xx: fix gpio settings

A previous changeset moved gpio from em28xx struct into em28xx_board.
However, the driver were not updated to properly honor those gpio's.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9762): em28xx: fix tuner absent entries
Mauro Carvalho Chehab [Thu, 27 Nov 2008 10:46:59 +0000 (07:46 -0300)]
V4L/DVB (9762): em28xx: fix tuner absent entries

Before this patch, several devices without tuner were kept the value 0
for tuner_type. However, this means TUNER_TEMIC_PAL. Replace those
entries for the proper TUNER_ABSENT value.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9761): em28xx: replace magic numbers for mux aliases
Mauro Carvalho Chehab [Thu, 27 Nov 2008 10:44:00 +0000 (07:44 -0300)]
V4L/DVB (9761): em28xx: replace magic numbers for mux aliases

Instead of using magic vmux/amux, let's use an alias where possible.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9760): em28xx: move gpio lines into board table description
Mauro Carvalho Chehab [Thu, 27 Nov 2008 10:42:26 +0000 (07:42 -0300)]
V4L/DVB (9760): em28xx: move gpio lines into board table description

Instead of a large, ugly switch specifying the gpio tables for each
device, let's move it into the boards struct. This also helps to see
what boards have already the gpio's for DVB.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9759): em28xx: move gpio tables to the top of em28xx-cards
Mauro Carvalho Chehab [Tue, 25 Nov 2008 16:16:13 +0000 (13:16 -0300)]
V4L/DVB (9759): em28xx: move gpio tables to the top of em28xx-cards

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9758): em28xx: replace some magic by register descriptions where known
Mauro Carvalho Chehab [Wed, 26 Nov 2008 19:28:42 +0000 (16:28 -0300)]
V4L/DVB (9758): em28xx: replace some magic by register descriptions where known

Replaces all occurrences of em28xx_write_regs_req() and em28xx_write_reg()
used to setup register names by em28xx_write_reg().

Also, documents the register names that are known.

This patch were generated by this small perl script:

my %reg_map = (
# Register table - the same as defined on parse_em28xx.pl script
);

while (<>) {
if (m/(.*)em28xx_write_regs_req\(dev\,\s*0x00\,\s*(.*)\,\s*\"\\x(..)\",\s*1\)\;(.*)/) {
my $reg = $2;
my $val = $3;
$val =~ tr/A-f/a-f/;
$reg = $reg_map{$reg} if defined($reg_map{$reg});
printf "$1em28xx_write_reg(dev, %s, 0x%s);$4\n", $reg, $val;
} elsif (m/(.*)em28xx_write_regs\(dev\,\s*(.*)\,\s*\"\\x(..)\",\s*1\)\;(.*)/) {
my $reg = $2;
my $val = $3;
$val =~ tr/A-f/a-f/;
$reg = $reg_map{$reg} if defined($reg_map{$reg});
printf "$1em28xx_write_reg(dev, %s, 0x%s);$4\n", $reg, $val;
} else {
print $_;
}
}

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9755): em28xx: cleanup: We need just one tuner callback
Mauro Carvalho Chehab [Tue, 25 Nov 2008 16:10:14 +0000 (13:10 -0300)]
V4L/DVB (9755): em28xx: cleanup: We need just one tuner callback

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9754): em28xx: improve debug messages
Mauro Carvalho Chehab [Tue, 25 Nov 2008 13:06:21 +0000 (10:06 -0300)]
V4L/DVB (9754): em28xx: improve debug messages

Now, the first message states board names. Also, removed printing the alternate
settings by default. I2C messages are now clearer.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9753): em28xx: cleanup: saa7115 module auto-detects saa711x type
Mauro Carvalho Chehab [Tue, 25 Nov 2008 12:43:29 +0000 (09:43 -0300)]
V4L/DVB (9753): em28xx: cleanup: saa7115 module auto-detects saa711x type

Since saa7115 has saa711x chip auto-detection, there's no need on differenciating
it at cards table. Just use the generic name for all boards that use a philips
saa711x decoder.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9752): Remove duplicated fields on em28xx_board and em28xx structs
Mauro Carvalho Chehab [Tue, 25 Nov 2008 12:39:50 +0000 (09:39 -0300)]
V4L/DVB (9752): Remove duplicated fields on em28xx_board and em28xx structs

Several fields are duplicated on both structs. Let's just copy em28xx_board instead.

A later cleanup could just copy the fields that are changed, in order to keep em28xx_board
const.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9751): em28xx: card description cleanups
Mauro Carvalho Chehab [Tue, 25 Nov 2008 12:10:25 +0000 (09:10 -0300)]
V4L/DVB (9751): em28xx: card description cleanups

Remove unused em28xx_board.vchannels and em28xx.video_channels.
Also, .is_em2800 = 0 is not needed, as all data is zeroed by kernel loader.

The table also included a notice that svideo weren't test on Hauppauge
USB2. Remove this notice, since this input also works properly.

Also, it does some whitespace cleanups.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9747): em28xx: Properly handles XCLK and I2C speed
Mauro Carvalho Chehab [Tue, 25 Nov 2008 10:05:06 +0000 (07:05 -0300)]
V4L/DVB (9747): em28xx: Properly handles XCLK and I2C speed

The previous patches removed XCLK and I2C magic. Now, we finally know
what those registers do. Also, only a very few cards need different
setups for those.

Instead of keeping the setups for those values inside the per-device
hack magic switch, move the uncommon values to the board-specific
struct, and have a common setup for all other boards.

So, almost 100 lines of hacking magic were removed.

A co-lateral effect of this patch is that it also fixes a bug at em28xx-core, where xclk
were set, without taking any care about not overriding a previous xclk setup.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9745): em28xx: Cleanup GPIO/GPO setup code
Devin Heitmueller [Tue, 25 Nov 2008 09:04:02 +0000 (06:04 -0300)]
V4L/DVB (9745): em28xx: Cleanup GPIO/GPO setup code

Cleanup the calls to set the GPIOs and GPOs for various devices,
replacing the register number with the #define from em28xx-reg.h and
converting over to using em28xx_write_reg()

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9744): em28xx: cleanup XCLK register usage
Devin Heitmueller [Tue, 25 Nov 2008 09:03:31 +0000 (06:03 -0300)]
V4L/DVB (9744): em28xx: cleanup XCLK register usage

Convert over to setting the XCLK register usage with the new em28xx_write_reg()
function.

Thanks to Ray Lu from Empia for providing the em2860/2880 datasheet.

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9740): sms1xxx: add USB suspend and hibernation support
Uri Shkolnik [Sat, 22 Nov 2008 17:08:46 +0000 (14:08 -0300)]
V4L/DVB (9740): sms1xxx: add USB suspend and hibernation support

This patch provides USB suspend and hibernation support
for Siano's SMS chipset based USB device

Signed-off-by: Uri Shkolnik <uris@siano-ms.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9739): sms1xxx: enable signal quality indicator LEDs on Hauppauge WinTV...
Michael Krufky [Sat, 22 Nov 2008 18:32:19 +0000 (15:32 -0300)]
V4L/DVB (9739): sms1xxx: enable signal quality indicator LEDs on Hauppauge WinTV MiniStick

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9738): sms1xxx: fix invalid unc readings
Michael Krufky [Sat, 22 Nov 2008 17:56:37 +0000 (14:56 -0300)]
V4L/DVB (9738): sms1xxx: fix invalid unc readings

Add function smsdvb_read_ucblocks to report uncorrectable error counts.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9736): sms1xxx: enable power LED on Hauppauge WinTV MiniStick
Michael Krufky [Sat, 22 Nov 2008 17:26:37 +0000 (14:26 -0300)]
V4L/DVB (9736): sms1xxx: enable power LED on Hauppauge WinTV MiniStick

Enable power LED while the frontend is in use.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9735): sms1xxx: turn off LEDs after initialization of Hauppauge WinTV MiniStick
Michael Krufky [Mon, 17 Nov 2008 01:45:42 +0000 (22:45 -0300)]
V4L/DVB (9735): sms1xxx: turn off LEDs after initialization of Hauppauge WinTV MiniStick

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9733): sms1xxx: add autodetection support for Hauppauge WinTV MiniCard
Michael Krufky [Sat, 22 Nov 2008 14:21:02 +0000 (11:21 -0300)]
V4L/DVB (9733): sms1xxx: add autodetection support for Hauppauge WinTV MiniCard

add USB IDs for Hauppauge WinTV MiniCard DVB-T

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9734): sms1xxx: add functions to configure and set gpio
Michael Krufky [Sun, 16 Nov 2008 21:01:58 +0000 (18:01 -0300)]
V4L/DVB (9734): sms1xxx: add functions to configure and set gpio

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9717): em28xx: improve message probing logs
Mauro Carvalho Chehab [Sat, 22 Nov 2008 13:50:38 +0000 (10:50 -0300)]
V4L/DVB (9717): em28xx: improve message probing logs

On some em28xx devices, there's an unused interface. This is printed on
the logs as an error. We can just ignore that interface.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9713): gspca: Add the ov534 webcams in the gspca documentation.
Jean-Francois Moine [Sat, 22 Nov 2008 08:35:49 +0000 (05:35 -0300)]
V4L/DVB (9713): gspca: Add the ov534 webcams in the gspca documentation.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9712): gspca:Subdriver ov534 added.
Antonio Ospite [Sat, 22 Nov 2008 08:23:39 +0000 (05:23 -0300)]
V4L/DVB (9712): gspca:Subdriver ov534 added.

The OmniVision OV534 is the USB bridge chip used in Sony Playstation EYE,
it is found also in other webcams like Hercules Blog Webcam and
Hercules Dualpix HD.
This driver is the port to gspca of a prototype driver by Mark Ferrell
based on vivi. The original code to initialize the camera and start the
capture is from Jim Paris on ps2dev.org, here integrated with the analysis
of the USB communications taken by the windows driver.

Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9711): gspca: Let gspca handle the webcams 045e:00f5 & 00f7 instead of sn9c102.
Jean-Francois Moine [Sat, 22 Nov 2008 07:53:31 +0000 (04:53 -0300)]
V4L/DVB (9711): gspca: Let gspca handle the webcams 045e:00f5 & 00f7 instead of sn9c102.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9709): gspca: Fix typos and name errors in Kconfig.
Jean-Francois Moine [Sat, 22 Nov 2008 07:17:06 +0000 (04:17 -0300)]
V4L/DVB (9709): gspca: Fix typos and name errors in Kconfig.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9708): gspca: Do the sn9c105 - ov7660 work again in sonixj.
Jean-Francois Moine [Fri, 21 Nov 2008 07:34:15 +0000 (04:34 -0300)]
V4L/DVB (9708): gspca: Do the sn9c105 - ov7660 work again in sonixj.

The sn9c105 and sn9c120 bridges must be differently programmed for the ov7660.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9706): gspca: Use the ref counting of v4l2 for disconnection.
Hans de Goede [Wed, 19 Nov 2008 20:10:47 +0000 (17:10 -0300)]
V4L/DVB (9706): gspca: Use the ref counting of v4l2 for disconnection.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9703): Move the s5k4aa vflip quirk table to the main sensor file in order...
Erik Andrén [Tue, 18 Nov 2008 17:38:10 +0000 (14:38 -0300)]
V4L/DVB (9703): Move the s5k4aa vflip quirk table to the main sensor file in order to avoid compilation errors on older kernels

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9702): Move the ov9650 vflip table to avoid compilation warnings on older...
Erik Andrén [Tue, 18 Nov 2008 17:36:53 +0000 (14:36 -0300)]
V4L/DVB (9702): Move the ov9650 vflip table to avoid compilation warnings on older kernels

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9701): Add a minor comment to the sensor init
Erik Andrén [Tue, 18 Nov 2008 17:32:27 +0000 (14:32 -0300)]
V4L/DVB (9701): Add a minor comment to the sensor init

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9698): Add another vflip quirk for the s5k4aa
Erik Andrén [Sat, 1 Nov 2008 16:13:03 +0000 (13:13 -0300)]
V4L/DVB (9698): Add another vflip quirk for the s5k4aa

The msi gx7xx range of computers seem to be a strange lot with lots of different sys vendor names and differently oriented sensors. This commit adds another quirk for a range of them.

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9696): Remove accidental typo
Erik Andrén [Sat, 18 Oct 2008 19:20:36 +0000 (16:20 -0300)]
V4L/DVB (9696): Remove accidental typo

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9694): Indent the m5602 register definitions
Erik Andrén [Tue, 14 Oct 2008 05:41:54 +0000 (02:41 -0300)]
V4L/DVB (9694): Indent the m5602 register definitions

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9693): Remove some unused defines
Erik Andrén [Tue, 14 Oct 2008 05:38:49 +0000 (02:38 -0300)]
V4L/DVB (9693): Remove some unused defines

The gspca conversion deprecated a number of defines. Remove them.

Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9688): gspca: Reset the bulk URB status before resubmitting at irq level.
Jean-Francois Moine [Tue, 18 Nov 2008 07:19:52 +0000 (04:19 -0300)]
V4L/DVB (9688): gspca: Reset the bulk URB status before resubmitting at irq level.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9687): gspca: Split brightness and red and blue balance in spca501.
Hans de Goede [Mon, 17 Nov 2008 18:03:03 +0000 (15:03 -0300)]
V4L/DVB (9687): gspca: Split brightness and red and blue balance in spca501.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9686): gspca: Don't return the control values from the webcams in spca501.
Hans de Goede [Mon, 17 Nov 2008 17:56:41 +0000 (14:56 -0300)]
V4L/DVB (9686): gspca: Don't return the control values from the webcams in spca501.

The bridge takes some time to update after a write, so apps doing a quick
write/read can get the old value back.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9685): gspca: Correct restart of webcams in spca501.
Hans de Goede [Mon, 17 Nov 2008 17:52:56 +0000 (14:52 -0300)]
V4L/DVB (9685): gspca: Correct restart of webcams in spca501.

Currently the spca501 driver only works the first time used, then the cam needs
to be unplugged or the driver reloaded, this is because currently the data
which should be send each time the stream is started is send only once.
Likewise currently the data to initialize the cam is send from the probe
function, and thus will not get send after a suspend/resume.
This patch fixes this by sending both at the right time.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9682): gspca: New subdriver parameter 'bulk_nurbs'.
Antonio Ospite [Fri, 14 Nov 2008 10:53:32 +0000 (07:53 -0300)]
V4L/DVB (9682): gspca: New subdriver parameter 'bulk_nurbs'.

Some webcams with image transfer by bulk messages accept one or many
permanent bulk read.

Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9681): gspca: Rewrite the exchanges with the sensor ov7648 of sonixj.
Jean-Francois Moine [Tue, 11 Nov 2008 11:42:56 +0000 (08:42 -0300)]
V4L/DVB (9681): gspca: Rewrite the exchanges with the sensor ov7648 of sonixj.

The new exchanges are adapted from MS-win traces and the webcams work better.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9680): gspca: Let gspca handle the webcam 0c45:613a instead of sn9c102.
Jean-Francois Moine [Tue, 11 Nov 2008 10:10:11 +0000 (07:10 -0300)]
V4L/DVB (9680): gspca: Let gspca handle the webcam 0c45:613a instead of sn9c102.

The driver sn9c102 has no code for the ov7648 sensor.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9678): af9015: Cleanup switch for usb ID
Hans Verkuil [Thu, 20 Nov 2008 08:37:05 +0000 (05:37 -0300)]
V4L/DVB (9678): af9015: Cleanup switch for usb ID

It is much more readable to swap the byteorder in the switch rather
than in each case statement.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9677): bttv: fix some entries on Phytec boards and add missing ones
Dirk Heer [Fri, 21 Nov 2008 22:00:55 +0000 (19:00 -0300)]
V4L/DVB (9677): bttv: fix some entries on Phytec boards and add missing ones

This Patch does modify the bttv-cards.c and bttc.h so that the driver
supports VD-011, VD-012, VD-012-X1 and VD-012-X2 Framegrabber from
Phytec Messtechnik GmbH.

Signed-off-by: Dirk Heer <d.heer@phytec.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9676): em28xx: fix a regression caused by 22c90ec6a5e07173ee670dc2ca75e0df0a...
Mauro Carvalho Chehab [Thu, 20 Nov 2008 21:47:37 +0000 (18:47 -0300)]
V4L/DVB (9676): em28xx: fix a regression caused by 22c90ec6a5e07173ee670dc2ca75e0df0a7772c0

If removing and reiserting the driver on some devices, tuner type will
be unset at the second time. This patch fixes this issue.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9675): em28xx: devices with xc2028/3028 don't have tda9887
Mauro Carvalho Chehab [Thu, 20 Nov 2008 21:38:29 +0000 (18:38 -0300)]
V4L/DVB (9675): em28xx: devices with xc2028/3028 don't have tda9887

This patch cleans up the entries of xc2028/3028, since those devices
don't need or use a tda9887.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9673): em28xx: fix Pixelview PlayTV board entry
Mauro Carvalho Chehab [Thu, 20 Nov 2008 16:43:05 +0000 (13:43 -0300)]
V4L/DVB (9673): em28xx: fix Pixelview PlayTV board entry

Pixelview uses a Sigmatel stac codec. It has an external line out pin,
connected to AC97_MASTER_VOL. It also provides I2S output, but using a

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9672): Allow opening more than one output at the same time
Mauro Carvalho Chehab [Thu, 20 Nov 2008 16:39:39 +0000 (13:39 -0300)]
V4L/DVB (9672): Allow opening more than one output at the same time

Some devices use more than one AC97 outputs. This patch allows such
devices to properly work.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9671): em28xx: Add detection of Sigmatel Stac97xx series of AC97 devices
Mauro Carvalho Chehab [Thu, 20 Nov 2008 15:49:33 +0000 (12:49 -0300)]
V4L/DVB (9671): em28xx: Add detection of Sigmatel Stac97xx series of AC97 devices

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9670): em28xx: allow specifying audio output
Mauro Carvalho Chehab [Thu, 20 Nov 2008 15:40:51 +0000 (12:40 -0300)]
V4L/DVB (9670): em28xx: allow specifying audio output

Some boards use different AC97 setups for output. This patch adds the
capability of specifying the output to be used. Currently, only one
output is selected, but the better is to allow user to select it via a
mixer, on alsa driver.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9669): em28xx: Fix a stupid cut-and-paste error
Mauro Carvalho Chehab [Thu, 20 Nov 2008 15:10:44 +0000 (12:10 -0300)]
V4L/DVB (9669): em28xx: Fix a stupid cut-and-paste error

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9667): Fixed typo in sizeof() causing NULL pointer OOPS
Oldrich Jedlicka [Fri, 14 Nov 2008 01:03:00 +0000 (22:03 -0300)]
V4L/DVB (9667): Fixed typo in sizeof() causing NULL pointer OOPS

Signed-off-by: Oldřich Jedlička <oldium.pro@seznam.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9665): af9015: Add support for the Digittrade DVB-T USB Stick remote
Alain Kalker [Mon, 17 Nov 2008 20:20:38 +0000 (17:20 -0300)]
V4L/DVB (9665): af9015: Add support for the Digittrade DVB-T USB Stick remote

Adds support for the Digittrade DVB-T USB Stick remote.
As the Digittrade USB stick identifies itself as a generic Afatech AF9015
device, the remote cannot be autodetected. To enable it, add the following
to /etc/modprobe.d/dvb-usb-af9015 or /etc/modprobe.conf:

options dvb-usb-af9015 remote=4

Signed-off-by: Alain Kalker <miki@dds.nl>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9662): uvcvideo: Fix printk badness when printing ioctl names
Laurent Pinchart [Mon, 17 Nov 2008 21:32:11 +0000 (18:32 -0300)]
V4L/DVB (9662): uvcvideo: Fix printk badness when printing ioctl names

Add a trailing newline character after calling v4l_printk_ioctl() to avoid
messing the kernel log up and merge the uvc_v4l2_ioctl message with the ioctl
name.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9661): uvcvideo: Commit streaming parameters when enabling the video stream
Laurent Pinchart [Wed, 12 Nov 2008 14:46:43 +0000 (11:46 -0300)]
V4L/DVB (9661): uvcvideo: Commit streaming parameters when enabling the video stream

Sonix-based cameras seem to require the host to commit video streaming
parameters before selecting the alternate endpoint. While most applications
issue a VIDIOC_S_FMT ioctl before starting streaming, this is not required
by the V4L2 specification.

The problem has been noticed on Ubuntu 8.10 with applications using libv4l.
The library blocks VIDIOC_S_FMT calls when the requested format is identical
to the currently selected format. As the driver commits video streaming
parameters when initialising the device, only the first run of a
libv4l-enabled application would succeed.

For the sake of completeness, experiment showed that the camera keeps sending
12 bytes isochronous packets (header only, no data) without toggling the FID
bit if video streaming parameters haven't been committed before selecting the
alternate endpoint.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9660): uvcvideo: Fix unaligned memory access.
Michael Hennerich [Tue, 11 Nov 2008 17:11:28 +0000 (14:11 -0300)]
V4L/DVB (9660): uvcvideo: Fix unaligned memory access.

Use the unaligned memory access macros when accessing unaligned memory.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9659): uvcvideo: Use {get|set}_unaligned_le32 macros
Laurent Pinchart [Tue, 11 Nov 2008 17:04:30 +0000 (14:04 -0300)]
V4L/DVB (9659): uvcvideo: Use {get|set}_unaligned_le32 macros

Replace combination of endianess conversion and unaligned access macros with
{get|set}_unaligned_*.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9658): em28xx: use em28xx_write_reg() for i2c clock setup
Devin Heitmueller [Thu, 20 Nov 2008 12:53:05 +0000 (09:53 -0300)]
V4L/DVB (9658): em28xx: use em28xx_write_reg() for i2c clock setup

Convert the calls that write the i2c clock register over to the new
em28xx_write_reg() function that allows for or'ing bits

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9657): em28xx: add a functio to write on a single register
Devin Heitmueller [Thu, 20 Nov 2008 12:52:20 +0000 (09:52 -0300)]
V4L/DVB (9657): em28xx: add a functio to write on a single register

Introduce a new function that writes to a single register.  This is
useful because the vast majority of register writes are a single
register, and this format permits or'ing register value bits together.

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9654): new email address
Jelle Foks [Thu, 20 Nov 2008 10:07:45 +0000 (07:07 -0300)]
V4L/DVB (9654): new email address

Please accept this patch to refer to my new email address

Signed-off-by: Jelle Foks <jelle@foks.us>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9653): em28xx: improve AC97 handling
Mauro Carvalho Chehab [Thu, 20 Nov 2008 12:06:09 +0000 (09:06 -0300)]
V4L/DVB (9653): em28xx: improve AC97 handling

AC97 devices provide several input and outputs. However, before this
patch, em28xx device weren't properly allowing the usage of ac97
possible combinations. Also, several input volumes were left untouched,
instead of making sure that the volumes were set on mute state.

This patch improves support for ac97 devices by allowing to use any
inputs, and making sure that unused inputs are set on mute state.

Yet, some work is still needed to select the AC97 output.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9652): em28xx: merge AC97 vendor id's into a single var
Mauro Carvalho Chehab [Thu, 20 Nov 2008 11:56:19 +0000 (08:56 -0300)]
V4L/DVB (9652): em28xx: merge AC97 vendor id's into a single var

This makes easier to identify vendor ID, since AC97 vendors are
generally identified by 3 bytes. The remaining byte is used by the
vendor to identify its devices.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9651): em28xx: Improve audio handling
Mauro Carvalho Chehab [Wed, 19 Nov 2008 15:01:33 +0000 (12:01 -0300)]
V4L/DVB (9651): em28xx: Improve audio handling

This patch properly implements audio handling on em28xx. Before this
patch, it was assumed that every device has an Empia 202 audio chip.
However, this is not true.

After this patch, specific AC97 chipset setup and configurations can be
done.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9650): em28xx: replace magic numbers to something more meaningful
Mauro Carvalho Chehab [Wed, 19 Nov 2008 14:10:50 +0000 (11:10 -0300)]
V4L/DVB (9650): em28xx: replace magic numbers to something more meaningful

audio mux entries were described by 0 and 1 magic numers. Use an enum
alias for each entry type.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9649): em28xx: remove two amux entries used only on one card
Mauro Carvalho Chehab [Wed, 19 Nov 2008 14:08:53 +0000 (11:08 -0300)]
V4L/DVB (9649): em28xx: remove two amux entries used only on one card

This patch parepares for an audio refactor patch that auto-detects ac97
chips.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9648): em28xx: get audio config from em28xx register
Devin Heitmueller [Wed, 19 Nov 2008 11:22:28 +0000 (08:22 -0300)]
V4L/DVB (9648): em28xx: get audio config from em28xx register

Make use of the em28xx chip configuration register to determine whether
we have AC97 audio, I2S audio, or no audio support at all.

Thanks for Ray Lu from Empia for providing the em2860/em2880 datasheet.

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9644): em28xx: add em2750 to the list of known em28xx chip ids
Devin Heitmueller [Tue, 18 Nov 2008 08:05:46 +0000 (05:05 -0300)]
V4L/DVB (9644): em28xx: add em2750 to the list of known em28xx chip ids

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9643): em28xx: remove the previous register names
Mauro Carvalho Chehab [Tue, 18 Nov 2008 01:40:36 +0000 (22:40 -0300)]
V4L/DVB (9643): em28xx: remove the previous register names

Previously, AC97 registers were named as if they were part of em28xx
device, generating some confusion. Replace such names for a more general
naming convention.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9642): Add AC97 registers found on em28xx devices
Mauro Carvalho Chehab [Tue, 18 Nov 2008 01:30:09 +0000 (22:30 -0300)]
V4L/DVB (9642): Add AC97 registers found on em28xx devices

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9641): Add chip ID's for em2820 and em2840
Mauro Carvalho Chehab [Sun, 16 Nov 2008 13:40:21 +0000 (10:40 -0300)]
V4L/DVB (9641): Add chip ID's for em2820 and em2840

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9638): drivers/media: use ARRAY_SIZE
Julia Lawall [Thu, 13 Nov 2008 02:18:21 +0000 (23:18 -0300)]
V4L/DVB (9638): drivers/media: use ARRAY_SIZE

ARRAY_SIZE is more concise to use when the size of an array is divided by
the size of its type or the size of its first element.

The semantic patch that makes this change is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@i@
@@

@depends on i using "paren.iso"@
type T;
T[] E;
@@

- (sizeof(E)/sizeof(E[...]))
+ ARRAY_SIZE(E)

@depends on i using "paren.iso"@
type T;
T[] E;
@@

- (sizeof(E)/sizeof(T))
+ ARRAY_SIZE(E)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9637): usb vendor_ids/product_ids are __le16
Harvey Harrison [Fri, 14 Nov 2008 21:19:56 +0000 (18:19 -0300)]
V4L/DVB (9637): usb vendor_ids/product_ids are __le16

Noticed by sparse:
drivers/media/dvb/dvb-usb/af9015.c:756:25: warning: restricted __le16 degrades to integer
drivers/media/dvb/dvb-usb/af9015.c:744:28: warning: restricted __le16 degrades to integer

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9636): dvb: cinergyt2 annotate struct endianness, remove unused variable...
Harvey Harrison [Sat, 15 Nov 2008 04:08:45 +0000 (01:08 -0300)]
V4L/DVB (9636): dvb: cinergyt2 annotate struct endianness, remove unused variable, add static

All noticed by sparse:
drivers/media/dvb/dvb-usb/cinergyT2-core.c:35:5: warning: symbol 'disable_remote' was not declared. Should it be static?
drivers/media/dvb/dvb-usb/cinergyT2-core.c:48:23: warning: symbol 'cinergyt2_usb_device' was not declared. Should it be static?
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:160:15: warning: cast to restricted __le16
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:190:9: warning: cast to restricted __le32
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:208:9: warning: cast to restricted __le32
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:227:24: warning: cast to restricted __le16
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:275:12: warning: incorrect type in assignment (different base types)
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:275:12:    expected unsigned short [unsigned] [assigned] [usertype] tps
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:275:12:    got restricted __le16 [usertype] <noident>
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:276:13: warning: incorrect type in assignment (different base types)
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:276:13:    expected unsigned int [unsigned] [assigned] [usertype] freq
drivers/media/dvb/dvb-usb/cinergyT2-fe.c:276:13:    got restricted __le32 [usertype] <noident>

Cc: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9633): Put s5h1411 into low power mode at end of attach() call
Devin Heitmueller [Sun, 16 Nov 2008 06:39:50 +0000 (03:39 -0300)]
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>