Commit Graph

8037 Commits

Author SHA1 Message Date
Michael Krufky 542cb05736 V4L/DVB (12873): saa7134: disable tda18271 slave tuner output / loop thru in standby mode
Enable the standby mode optimization to disable the tda18271
slave tuner output / loop thru options when in low power mode

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:55 -03:00
Henk Vergonet d1f7510b91 V4L/DVB (12871): tda18271: fix bad data in tda18271_cid_target table
Fixed one value and removed a duplicate in tda18271_cid_target[],
based on table 54 "CID_Target_map" in Rev.04 of the TDA18271HD datasheet.

Signed-off-by: Henk Vergonet <Henk.Vergonet@gmail.com>
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:52 -03:00
Henk Vergonet b5d189702b V4L/DVB (12870): tda18271: update temperature compensation calculatation formula
Update the tda18271c2_rf_tracking_filters_correction function to include
the modified temperature compensation calculatation formula as described
in Rev.04 of the TDA18271HD datasheet.

Signed-off-by: Henk Vergonet <Henk.Vergonet@gmail.com>
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:50 -03:00
Michael Krufky ecda427340 V4L/DVB (12869): tda18271: fix comments and make tda18271_agc debug less verbose
Don't display "no agc configuration provided" unless DBG_ADV is set.

Fix comments in function, tda18271_agc.  This config variable is not
for LNA configuration -- it is for external AGC configuration.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:49 -03:00
Michael Krufky 650901c0b6 V4L/DVB (12868): tda18271: improve error log in function tda18271_write_regs
Display function parameters, idx and len, in error log.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:48 -03:00
Michael Krufky d5abef6be1 V4L/DVB (12867): tda18271: ensure that configuration options are set for multiple instances
For the case of multiple tuner instances, ensure that non-default
configuration options are saved into the driver's state.

This resolves an issue where a configuration option may not be
carried into the driver if the analog side of a hybrid driver
initializes before the digital side.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:47 -03:00
Michael Krufky 1216531a1f V4L/DVB (12866): tda18271: move small_i2c assignment to the state config block
minor cleanup: move small_i2c assignment to the state config block

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:45 -03:00
Michael Krufky cc7e26d47f V4L/DVB (12865): tda18271: move tda18271_sleep directly below tda18271_init
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:44 -03:00
Michael Krufky 4240b460f0 V4L/DVB (12864): tda18271: change output feature configuration to a bitmask
For better readability, treat the low power standby mode configuration
as an output option feature configuration, and change it to a bitmask.

If left unconfigured, all features will remain enabled, just as the
default configuration was before these changes were introduced.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:43 -03:00
Michael Krufky 2dfca76303 V4L/DVB (12863): tda18271: add new standby mode: slave tuner output / loop thru on
Add new standby mode:
TDA18271_STANDBY_LT_ON = slave tuner output loop thru on w/ xtal osc off

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:41 -03:00
Michael Krufky 72c8364a66 V4L/DVB (12862): tda18271: add debug to show which standby mode is in use
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:40 -03:00
Michael Krufky 81259f210e V4L/DVB (12861): tda18271: add support for additional low-power standby modes
By default, the driver enters standby mode with slave tuner output
loop thru enabled and xtal oscillator on.

Not all designs require that slave tuner output loop thru and
xtal oscillator remain active while in standby mode, so two
additional standby modes have been added:

- standby mode with xtal oscillator on (loop thru off)

- total power off

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-19 00:13:39 -03:00
Antti Palosaari f4e96deb45 V4L/DVB (12756): af9015: fix typo in register compare
And mask should be 0xff00 instead of 0xae00.

Thanks to Jochen Friedrich <jochen@scram.de> for pointing this.

Cc: Jochen Friedrich <jochen@scram.de>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:54 -03:00
Antti Palosaari 06565d7a42 V4L/DVB (12755): af9015: improve usb control message function slightly
* define names for few values
* decrease buffer len by one byte which was not used
* add check for buffer overflow for sure
* indentation fixes
* remove useless 0 len check from memcpy
It should not happen and if it happens memcpy should not do anything.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:53 -03:00
Antti Palosaari 9c86327809 V4L/DVB (12754): af9015: [2/2] fix USB TS configuration
Fix wrongly configured USB1.1 TS EP.

Patch serie also increases USB URB size to reduce wakeups.
USB1.1 URB size from 64 to 940 bytes
USB2.0 URB size from 512 to 16356 bytes

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:53 -03:00
Jose Alberto Reguero 353330c3eb V4L/DVB (12753): af9015: [1/2] fix USB TS configuration
Fix wrongly configured USB2.0 TS EP.

Signed-off-by: Jose Alberto Reguero <jareguero@telefonica.net>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:52 -03:00
Devin Heitmueller 891114a413 V4L/DVB (12750): em28xx: fix unused variable warning
Remove unused variable from when I introduced the g_std() function.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:49 -03:00
Devin Heitmueller 10e0125502 V4L/DVB (12749): em28xx: remove unneeded code that set VINCTRL register
Remove redundant call to set the vinctrl register.  This eliminates any
ambiguity as to how the register is configured (since it is now always set in
em28xx_set_outfmt).

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:45 -03:00
Devin Heitmueller 19bf00384a V4L/DVB (12748): em28xx: implement g_std v4l call
We need to implement the g_std call, or else the default norm always gets
returned, which breaks VBI capturing if you had changed the standard to NTSC
using s_std.

I had temporarily changed the default norm to NTSC so that zvbi-ntsc-cc
wouldn't choke, so now that we are returning the correct value, switch it back
to PAL as the default.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:45 -03:00
Devin Heitmueller 0414614aab V4L/DVB (12747): em28xx: only advertise VBI capability if supported
Change the code so we only claim to support VBI if the underlying chipset
actually has the support.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:44 -03:00
Devin Heitmueller 290c0cfac9 V4L/DVB (12746): em28xx: do not create /dev/vbiX device if VBI not supported
Do not create the VBI device in cases where VBI is not supported on the target
em28xx chip.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:43 -03:00
Devin Heitmueller 365adee851 V4L/DVB (12745): em28xx: remove unreferenced variable
Remove an unreferenced variable introduced during the VBI introduction.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:42 -03:00
Devin Heitmueller 8c873d31af V4L/DVB (12744): em28xx: restructure fh/dev locking to handle both video and vbi
The current locking infrastructure didn't support having multiple fds accessing
the device (such as video and vbi).  Rework the locking infrastructure,
borrowing the design from cx88.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:42 -03:00
Devin Heitmueller 91f6dcec92 V4L/DVB (12743): em28xx: fix mmap_mapper with vbi
When adding support for both video and VBI, I missed the mmap ioctl.  Add
the missing call.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:42 -03:00
Devin Heitmueller 28abf083d3 V4L/DVB (12742): em28xx: add raw VBI support for NTSC
Add support for raw VBI capture for the em28xx bridge, currently only for
NTSC.  Support for PAL capture to follow shortly (including the removal of
numerous hard-coded NTSC-specific sizes for capture buffers, etc).

Note that the code currently changes the default current norm from PAL to
NTSC (so that zvbi-ntsc-cc works properly).  The default norm really should
be moved into a board-level parameter.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:41 -03:00
Devin Heitmueller da52a55cff V4L/DVB (12741): em28xx: make video isoc stream work when VBI is enabled
Add code enabling the VBI registers for variants of the em28xx chip that
support VBI, and make sure the isoc streaming code continues to work for
the video component of the stream (note the video and vbi data arrive
intermixed on the same isoc pipe).

Note that this version just drops the actual VBI data onto the floor as
opposed to processing it.  The "#ifdef 0" tags are for the videobuf code that
appears in the next patch in this series.

We created a separate version of the isoc_copy version for parsing the version
of the stream that includes VBI data.  In theory, they might be able to be
merged at some point in the future, but the initial goal is to ensure that we
do not cause any regressions with devices that do not have VBI support.

This work was sponsored by EyeMagnet Limited.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:40 -03:00
Devin Heitmueller 206313db83 V4L/DVB (12740): em28xx: better describe vinctrl registers
Properly document the video input control register, in preparation for the
addition of VBI support.  Note this patch makes no functional changes.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-18 23:47:40 -03:00
Paul Mundt ea88023b34 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts:
	arch/sh/kernel/vmlinux.lds.S
2009-09-16 13:48:32 +09:00
Linus Torvalds 043fe50f80 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (213 commits)
  V4L/DVB (12720): em28xx-cards: Add vendor/product id for Kworld DVD Maker 2
  V4L/DVB (12713): em28xx: Cleanups at ir_i2c handler
  V4L/DVB (12712): em28xx: properly load ir-kbd-i2c when needed
  V4L/DVB (12701): saa7134: ir-kbd-i2c init data needs a persistent object
  V4L/DVB (12699): cx18: ir-kbd-i2c initialization data should point to a persistent object
  V4L/DVB (12698): em28xx: ir-kbd-i2c init data needs a persistent object
  V4L/DVB (12707): gspca - sn9c20x: Add SXGA support to MT9M111
  V4L/DVB (12706): gspca - sn9c20x: disable exposure/gain controls for MT9M111 sensors.
  V4L/DVB (12705): gspca - sn9c20x: Add SXGA support to SOI968
  V4L/DVB (12703): gspca - sn9c20x: Reduces size of object
  V4L/DVB (12704): gspca - sn9c20x: Fix exposure on SOI968 sensors
  V4L/DVB (12696): gspca - sonixj / sn9c102: Two drivers for 0c45:60fc and 0c45:613e.
  V4L/DVB (12695): gspca - vc032x: Do the LED work with the sensor hv7131r.
  V4L/DVB (12694): gspca - vc032x: Change the start exchanges of the sensor hv7131r.
  V4L/DVB (12693): gspca - sunplus: The brightness is signed.
  V4L/DVB (12692): gspca - sunplus: Optimize code.
  V4L/DVB (12691): gspca - sonixj: Don't use mdelay().
  V4L/DVB (12690): gspca - pac7311: Webcam 06f8:3009 added.
  V4L/DVB (12686): dvb-core: check supported QAM modulations
  V4L/DVB (12685): dvb-core: check fe->ops.set_frontend return value
  ...
2009-09-15 09:22:18 -07:00
Douglas Schilling Landgraf ea47689e74 V4L/DVB (12720): em28xx-cards: Add vendor/product id for Kworld DVD Maker 2
Added Kworld DVD Maker 2
Thanks to C Western <l@c-m-w.me.uk> for reporting this board.

Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-14 22:39:19 -03:00
Linus Torvalds d7e9660ad9 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1623 commits)
  netxen: update copyright
  netxen: fix tx timeout recovery
  netxen: fix file firmware leak
  netxen: improve pci memory access
  netxen: change firmware write size
  tg3: Fix return ring size breakage
  netxen: build fix for INET=n
  cdc-phonet: autoconfigure Phonet address
  Phonet: back-end for autoconfigured addresses
  Phonet: fix netlink address dump error handling
  ipv6: Add IFA_F_DADFAILED flag
  net: Add DEVTYPE support for Ethernet based devices
  mv643xx_eth.c: remove unused txq_set_wrr()
  ucc_geth: Fix hangs after switching from full to half duplex
  ucc_geth: Rearrange some code to avoid forward declarations
  phy/marvell: Make non-aneg speed/duplex forcing work for 88E1111 PHYs
  drivers/net/phy: introduce missing kfree
  drivers/net/wan: introduce missing kfree
  net: force bridge module(s) to be GPL
  Subject: [PATCH] appletalk: Fix skb leak when ipddp interface is not loaded
  ...

Fixed up trivial conflicts:

 - arch/x86/include/asm/socket.h

   converted to <asm-generic/socket.h> in the x86 tree.  The generic
   header has the same new #define's, so that works out fine.

 - drivers/net/tun.c

   fix conflict between 89f56d1e9 ("tun: reuse struct sock fields") that
   switched over to using 'tun->socket.sk' instead of the redundantly
   available (and thus removed) 'tun->sk', and 2b980dbd ("lsm: Add hooks
   to the TUN driver") which added a new 'tun->sk' use.

   Noted in 'next' by Stephen Rothwell.
2009-09-14 10:37:28 -07:00
Mauro Carvalho Chehab 7e8e16ca39 V4L/DVB (12713): em28xx: Cleanups at ir_i2c handler
There are some extra parenthesis at the clauses, and some switch() tests
for boards that don't have i2c ir. Remove those extra code.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 13:47:44 -03:00
Mauro Carvalho Chehab ac07bb73fe V4L/DVB (12712): em28xx: properly load ir-kbd-i2c when needed
Currently, the logic to load ir i2c ancillary module is broken. It is
associated to Hauppauge devices with IR flag on their eeprom, no matter
if the device uses i2c or em28xx direct IR support. That's wrong.

Instead, add a flag to the boards that use i2c IR chips and load the
module only for those devices and if ir is not disabled.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 13:47:34 -03:00
Mauro Carvalho Chehab 7aedd5ec87 V4L/DVB (12701): saa7134: ir-kbd-i2c init data needs a persistent object
ir-kbd-i2c's ir_probe() function can be called much later (i.e. at
ir-kbd-i2c module load), than the lifetime of a struct IR_i2c_init_data
allocated off of the stack in cx18_i2c_new_ir() at registration time.
Make sure we pass a pointer to a persistent IR_i2c_init_data object at
i2c registration time.

Thanks to Brian Rogers, Dustin Mitchell, Andy Walls and Jean Delvare to
rise this question.

Before this patch, if ir-kbd-i2c were probed after SAA7134, trash data
were used.

Compile tested only, but the patch is identical to em28xx one. So, it
should work properly.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:17 -03:00
Andy Walls 78f2e672b3 V4L/DVB (12699): cx18: ir-kbd-i2c initialization data should point to a persistent object
ir-kbd-i2c's ir_probe() function can be called much later (i.e. at ir-kbd-i2c
module load), than the lifetime of a struct IR_i2c_init_data allocated off of
the stack in cx18_i2c_new_ir() at registration time.  Make sure we pass
a pointer to a persistent IR_i2c_init_data object at i2c registration time.

Thanks to Brian Rogers for pointing out a solution, and Dustin Mitchell for
testing against a 2.6.30 kernel.

Reported-by: Dustin Mitchell <soxslayer@gmail.com>
Reported-by: Brian Rogers <brian@xyzw.org>
Tested-by: Dustin Mitchell <soxslayer@gmail.com>
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:15 -03:00
Mauro Carvalho Chehab d2ebd0f806 V4L/DVB (12698): em28xx: ir-kbd-i2c init data needs a persistent object
ir-kbd-i2c's ir_probe() function can be called much later (i.e. at
ir-kbd-i2c module load), than the lifetime of a struct IR_i2c_init_data
allocated off of the stack in cx18_i2c_new_ir() at registration time.
Make sure we pass a pointer to a persistent IR_i2c_init_data object at
i2c registration time.

Thanks to Brian Rogers, Dustin Mitchell, Andy Walls and Jean Delvare to
rise this question.

Before this patch, if ir-kbd-i2c were probed after em28xx, trash data
were used. After the patch, no matter what order, it is properly
reported as tested by me:

input: i2c IR (i2c IR (EM2840 Hauppaug as /class/input/input10
ir-kbd-i2c: i2c IR (i2c IR (EM2840 Hauppaug detected at i2c-4/4-0030/ir0 [em28xx #0]

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:15 -03:00
Brian Johnson 4d708a5e9e V4L/DVB (12707): gspca - sn9c20x: Add SXGA support to MT9M111
Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:14 -03:00
Brian Johnson 13a84fa4de V4L/DVB (12706): gspca - sn9c20x: disable exposure/gain controls for MT9M111 sensors.
Using the MT9M111's IFP to handle exposure/gain gives better results.

Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:14 -03:00
Brian Johnson e8b7acc180 V4L/DVB (12705): gspca - sn9c20x: Add SXGA support to SOI968
Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:13 -03:00
Joe Perches 58aa68c2fb V4L/DVB (12703): gspca - sn9c20x: Reduces size of object
Use s16 instead of int where possible.
Use struct instead of arrays

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:12 -03:00
Brian Johnson e143047129 V4L/DVB (12704): gspca - sn9c20x: Fix exposure on SOI968 sensors
Fixes broken exposure on SOI968 webcams that was causing
the camera to display a black screen

Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:11 -03:00
Jean-Francois Moine f077b0a648 V4L/DVB (12696): gspca - sonixj / sn9c102: Two drivers for 0c45:60fc and 0c45:613e.
Let 0c45:60fc in sn9c102 and 0c45:613e in gspca-sonixj (sensor not supported).

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:10 -03:00
Jean-Francois Moine ae310ee109 V4L/DVB (12695): gspca - vc032x: Do the LED work with the sensor hv7131r.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:09 -03:00
Jean-Francois Moine 0ee7e4d6d4 V4L/DVB (12694): gspca - vc032x: Change the start exchanges of the sensor hv7131r.
The new exchanges are taken from the information file of the ms-win driver
(usbvm326.inf - webcam 15b8:6002).

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:09 -03:00
Jean-Francois Moine 760f2713cb V4L/DVB (12693): gspca - sunplus: The brightness is signed.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:08 -03:00
Jean-Francois Moine 2e1794b51b V4L/DVB (12692): gspca - sunplus: Optimize code.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:07 -03:00
Jean-Francois Moine 1f78a976ce V4L/DVB (12691): gspca - sonixj: Don't use mdelay().
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:05 -03:00
Stephane Marguet (Stemp) b5948bee13 V4L/DVB (12690): gspca - pac7311: Webcam 06f8:3009 added.
Signed-off-by: Stephane Marguet (Stemp) <smarguet@gmail.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:04 -03:00
Janne Grunau f51fad85af V4L/DVB (12686): dvb-core: check supported QAM modulations
Check the modulation in dvb_frontend_check_parameters against
frontend's capabilties for FE_QAM devices.

Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:04 -03:00
Janne Grunau 01886255dd V4L/DVB (12685): dvb-core: check fe->ops.set_frontend return value
Various frontend driver have parameter checks in their set_frontend
functions and return an error if the parameters are not supported,
tda10021 and cx24116 to name two.

The tuning ioctls FE_SET_FRONTEND/FE_SET_PROPERTY only change values
in the property cache and return before set_frontend is called. If a
set_frontend call in software zigzag algorithm fails and the card was
previously locked it will report a lock and the new parameters but is
still tuned to the old transport. This is not detectable from
userspace.

This change checks the return values of fe->ops.set_frontend and
changes the state to the added FESTATE_ERROR for software zigzag.
No lock will be reported to userspace if the State is FESTATE_ERROR.

Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:03 -03:00
Janne Grunau 4457ef1d61 V4L/DVB (12684): DVB: make DVB_MAX_ADAPTERS configurable
Support for more than 8 DVB devices is requested regularly so make it
a kconfig variable instead of a header define. Values in the range 4-32
are tested.

Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:03 -03:00
Hans de Goede f9089b0f9e V4L/DVB (12627): gspca_mr97310a: Add one more vivitar mini cam to the list of CIF cams
gspca_mr97310a: Add one more vivitar mini cam to the list of CIF cams

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:02 -03:00
Hans de Goede 780287061b V4L/DVB (12626): gspca_mr97310a: Allow overriding of detected sensor type
gspca_mr97310a: Allow overriding of detected sensor type

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:20:00 -03:00
Hans de Goede 823902defe V4L/DVB (12624): gspca_mr97310a: Use correct register for CIF type 1 sensor gain settings
gspca_mr97310a: Use correct register for CIF type 1 sensor gain settings

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:59 -03:00
Hans de Goede a2e081b64e V4L/DVB (12623): gspca_mr97310a: Add controls for CIF type 0 sensor cams
gspca_mr97310a: Add controls for CIF type 0 sensor cams

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:58 -03:00
Hans de Goede 5494378911 V4L/DVB (12622): gspca_mr97310a: make the probing a bit less chatty
gspca_mr97310a: make the probing a bit less chatty

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:58 -03:00
Hans de Goede 5f5e26b1e6 V4L/DVB (12621): gspca_mr97310a: Move detection of CIF sensor type to probe() function
gspca_mr97310a: Move detection of CIF sensor type to probe() function,
so that the right controls are set to disabled from the start, rather then
having them disappear all of a sudden when the stream is started.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:57 -03:00
Hans de Goede 9ac6978a10 V4L/DVB (12620): gspca_mr97310a: cleanup/fixup control handling
gspca_mr97310a: cleanup/fixup control handling

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:55 -03:00
Hans de Goede 58d0b2f66e V4L/DVB (12619): gspca: mr97310a fix detection of sensortype for vivicam with id byte of 0x53
gspca: mr97310a fix detection of sensortype for vivicam with id byte of 0x53

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:54 -03:00
Theodore Kilgore 89f0863c42 V4L/DVB (12618): gspca: mr97310a add support for CIF and more VGA camera's
This patch adds supports for mr97310a camera's with CIF sensors (2 different
types) and for VGA mr97310a camera with a different sensor then supported
until now.

This patch also add support for controls for one of the 2 CIF sensors, this
was written by Thomas Kaiser <thomas@kaiser-linux.li>

Signed-off-by: Theodore Kilgore <kilgota@auburn.edu>
Signed-off-by: Thomas Kaiser <thomas@kaiser-linux.li>
Signed-off-by: Hans de Goede <hdgoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:54 -03:00
Hans de Goede 0e4a90993d V4L/DVB (12617): gspca_pac207: enable higher framerates / lower exposure settings
Now that we've figured out the higher compression settings (supported in
libv4l-0.6.0 and later, so after this patch the driver should be used with
libv4l-0.6.0 or higher only!), we can enable higher framerates. Which
means lower exposure times, which is important for the use of the pac207
in full daylight.

This patch also tweakes the brightness default and the per color gain
balances to use the values which are adviced by Pixart in the pac207
application note.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:53 -03:00
Hans de Goede c529e556f6 V4L/DVB (12616): gspca_pac207: remove a number of unneeded (repeated) register writes
gspca_pac207: remove a number of unneeded (repeated) register writes

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:53 -03:00
Hans Verkuil 8d81ae2431 V4L/DVB (12613): cx25840: fix determining the firmware name
Depending on the model there are three different firmwares to choose from.
Unfortunately if a cx23885 is loaded first, then the global firmware name
is overwritten with that firmware and if ivtv is loaded next, then it
tries to load the wrong firmware. In addition, the original approach would
also overwrite any firmware that the user specified explicitly.

Cc: Jarod Wilson <jarod@wilsonet.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:52 -03:00
Hans Verkuil a65f315924 V4L/DVB (12612): si4713: simplify the code to remove a compiler warning.
The compiler warned about an uninitialized stereo variable. By simplifying
the code it 1) improved readability and 2) fixed the compiler warning.

Acked-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:50 -03:00
Mauro Carvalho Chehab a4c1cbc781 V4L/DVB (12600): dvb-usb-remote: return KEY_RESERVED if there's free space for new keys
The input subsystem checks if get_keycode works for a scan code. Due to that,
we need to return a valid value when there's some space at the table that
can be used by a scancode.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:49 -03:00
Mauro Carvalho Chehab b77f0a7630 V4L/DVB (12599): dvb-usb-remote: Allow dynamically replacing the IR keycodes
Implements handler for EVIOCGKEYCODE/EVIOCSKEYCODE via adding two new callbacks
to the input device.

Since on dvb-usb a scan code has 16 bits, to fulfill rc5 standard codes, the default
getkeycode/setkeycode input methods would require the driver to spend up to 64 Kb of
a sparse table. Instead, add two new callbacks to the event device.

With this, it is now possible to replace the keycode tables. There are, however, a few
implementation details at the current patch:

1) It will replace the existing device keytable, instead of creating an instance
of the data. This works. However, if two devices pointing to the same table
were connected, changing the IR table of one will also change the IR table for
the other (the solution for this one is simple: just kmalloc some memory);

2) In order to change the scan code, you need first to change the key to
KEY_RESERVED or KEY_UNKNOWN to free some space at the table (solution: allocate
some additional space for newer scan codes or allow dynamic table grow);

3) The table size cannot be extended. It would be easy to allow the table to
grow dynamically: just calling kmalloc(size+1); kfree(old). Yet, maybe we can
just create a bigger table with a fixed size, like for example a table with 128
entries. This should be enough even for a very big IR.

The current issues should be addressed on a later patch.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:48 -03:00
Mauro Carvalho Chehab 2e3658836e V4L/DVB (12598): dvb-usb: store rc5 custom and data at the same field
In order to be closer to V4L IR implementation, it is needed to replace
	u8 custom, data
to:
	u16 scan

This allows using non-rc5 mappings, like the 8 bit keycodes used on older
protocols. It will also allow future implementations of rc6 keystrokes
when needed.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:48 -03:00
Mauro Carvalho Chehab 715a223323 V4L/DVB (12595): common/ir: use a struct for keycode tables
Currently, V4L uses a scancode table whose index is the scancode and
the value is the keycode. While this works, it has some drawbacks:

1) It requires that the scancode to be at the range 00-7f;

2) keycodes should be masked on 7 bits in order for it to work;

3) due to the 7 bits approach, sometimes it is not possible to replace
the default keyboard to another one with a different encoding rule;

4) it is different than what is done with dvb-usb approach;

5) it requires a typedef for it to work. This is not a recommended
Linux CodingStyle.

This patch is part of a larger series of IR changes. It basically
replaces the IR_KEYTAB_TYPE tables by a structured table:
struct ir_scancode {
       u16     scancode;
       u32     keycode;
};

This is very close to what dvb does. So, a further integration with DVB
code will be easy.

While we've changed the tables, for now, the IR keycode handling is still
based on the old approach.

The only notable effect is the redution of about 35% of the ir-common
module size:

   text    data     bss     dec     hex filename
   6721   29208       4   35933    8c5d old/ir-common.ko
   5756   18040       4   23800    5cf8 new/ir-common.ko

In thesis, we could be using above u8 for scancode, reducing even more the size
of the module, but defining it as u16 is more convenient, since, on dvb, each
scancode has up to 16 bits, and we currently have a few troubles with rc5, as their
scancodes are defined with more than 8 bits.

This patch itself shouldn't be doing any functional changes.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:47 -03:00
Jean-Francois Moine 47f7f6fb79 V4L/DVB (12501): gspca - sonixj: Do the ov7660 sensor work again.
- bad sensor power
- bad edge gain/threshold
- set back the auto gain
- light frequency filter inverted

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:46 -03:00
Mauro Carvalho Chehab 5706934967 V4L/DVB (12469): fix bad whitespaces at cx88_geniatech_x8000_mt
It were using 7 spaces instead of tab for indent.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:45 -03:00
Mauro Carvalho Chehab 6d888a66be V4L/DVB (12591): em28xx: Add entry for GADMEI UTV330+ and related IR keymap
[mchehab@redhat.com: Fix a few wrong IR keymaps]
Signed-off-by: Shine Liu <shinel@foxmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:44 -03:00
Eugene Yudin 23389b8852 V4L/DVB (12589): Add support for RoverMedia TV Link Pro FM
This patch add support for RoverMedia TV Link Pro FM (LR138 REV:I) card
based on saa7134.

Signed-off-by: Eugene Yudin <Eugene.Yudin@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:43 -03:00
Dmitri Belimov 2012c87f83 V4L/DVB (12587): Add support BeholdTV X7 card
Add support our new TV card based on xc5000 and saa7134.
Analog TV works well.

Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:42 -03:00
Oldřich Jedlička 736dadaa17 V4L/DVB (12586): Update ALSA capture controls according to selected source.
The patch introduces new snd_saa7134_capsrc_set (code taken from
snd_saa7134_capsrc_put) that updates also the ALSA capture controls during
snd_card_saa7134_capture_prepare and snd_saa7134_capsrc_put.

There can be much more work done in order to unify the control of the card
(now the card's capture source is tuned/switched in saa7134-video.c too), but
I don't have enough time. This work could be a starting point, but it can be
applied as-is too (it doesn't need any further work to make it working).

Signed-off-by: Oldřich Jedlička <oldium.pro@seznam.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:41 -03:00
Mauro Carvalho Chehab ed44f66e40 V4L/DVB (12585): Add remote support to cph03x bttv card
Hello kernel developers.
I found a bug report from an user in launchpad. I just copy it here. It
includes patch.

I don't own the necessary hardware to test it but the patch looks
trivial.

I'm not subscribed to this list, so please CC me. Thanks!

Here is the text:

"""
remote control for my tv card doesnt work

I have Askey CPH03x TV Capturer.
When I load bttv module with "card=59" option which is proper for this
tv card,
I can watch tv with sound but my remote control doesnt work. There is no
ir
event in /proc/bus/input/device .
When bttv module is loaded with "card=137" option remote control works
very
well.

$ cat /proc/bus/input/devices
.......
........
: Bus=0001 Vendor=109e Product=0350 Version=0001
N: Name="bttv IR (card=137)"
P: Phys=pci-0000:00:0d.0/ir0
S: Sysfs=/devices/pci0000:00/0000:00:0d.0/input/input144
U: Uniq=
H: Handlers=kbd event6
B: EV=100003
B: KEY=2c0814 100004 0 0 0 4 2008000 2090 2001 1e0000 4400 0 ffc

Unfortunately there is no sound.
"""

https://bugs.launchpad.net/ubuntu/+bug/239733
http://bugzilla.kernel.org/show_bug.cgi?id=11995

--

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:39 -03:00
James A Webb 200e861c51 V4L/DVB (12584): Support for Kaiser Baas ExpressCard Dual HD Tuner
The card is reported as YUAN High-Tech Development Co., Ltd STK7700D

[mchehab@redhat.com: fix merge conflicts and properly name USB PID]
Cc: Patrick Boettcher <patrick.boettcher@desy.de>
Signed-off-by: James A Webb <jamesawebb@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:39 -03:00
Stefan Richter 96e242a594 V4L/DVB (12583): firedtv: combine some debug logging code
Shrinks source and kernel object size a bit.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:38 -03:00
Henrik Kurelid 15344779b2 V4L/DVB (12582): The current AVC debugging can clog the log down a lot since many
applications tend to check the signal strength very often.  This patch
enables users to select which AVC messages to log using a bitmask.  In
addition, it also enables the possibility to debug application PMTs sent
to the driver.  This will be usable since the CA support is still poorly
tested for lots of CAMs and CA systems.

Signed-off-by: Henrik Kurelid <henrik@kurelid.se>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:38 -03:00
Michael Krufky 81016b496e V4L/DVB (12578): tda18271: allow drivers to request RF tracking filter calibration during attach
On certain master / slave dual tuner configurations, tuning performance
improves when the RF tracking filter calibration is performed sequentially.

This patch allows for the bridge driver to specify this behavior in the
configuration structure at attach-time.

The "cal" module option will continue to override this attach-time
configuration: set cal=0 to prevent RF tracking filter calibration
on startup, and set cal=1 to force it.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Reviewed-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:37 -03:00
Michael Krufky ee8145d563 V4L/DVB (12577): tda18271: remove excess whitespace from tda_foo printk macros
remove excess spacing from the tda_foo printk macros & line things up better

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:35 -03:00
Michael Krufky 1b6b73336d V4L/DVB (12576): tda18271: simplify debug printk macros
Rename dprintk to tda_dprintk to be consistent with the other tda_foo macros.

Move KERN_DEBUG facility level to tda_dprintk.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:34 -03:00
Roel Kluin 8e30ddcf2f V4L/DVB (12575): Fix test of bandwidth range in cx22700_set_tps()
For the bandwidth to be less than 8 MHZ and greater than 6 MHZ is logically
impossible.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:34 -03:00
Vasiliy Temnikov 5a5e1da579 V4L/DVB (12574): support AverMedia Studio 505
Added support to AverMedia Studio 505

[dougsland@redhat.com: fixed rejects and removed the change to add dk as default secam variant]
[mchehab@redhat.com: fix a few CodingStyle issues]
Signed-off-by: Vasiliy Temnikov <vaka@newmail.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:33 -03:00
Dmitri Belimov 5bc53a9f91 V4L/DVB (12573): FM1216MK5 FM radio
Implement Philips FM1216MK5.

1. Implement get_stereo function.
2. Add correct data byte for FM radio mode

Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:33 -03:00
Mauro Carvalho Chehab 092315a76c V4L/DVB (12567): ir-keymaps: use KEY_CAMERA for snapshots
KEY_CAMERA is already used for a long time with webcam drivers to take a picture.
On other media drivers, due to the lack of a snapshot button, random KEY codes
were sent, being KEY_SHUFFLE the most used one, probably due to cut-and-paste
from other remotes, since one of them uses the same key for snapshot and shuffle.

The better is to use KEY_CAMERA on all drivers solving this issue. This
follows the IR standard map as defined at:
	http://linuxtv.org/wiki/index.php/Remote_Controllers

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:32 -03:00
Mauro Carvalho Chehab cd748871fe V4L/DVB (12566): ir-keymaps: Fix IR mappings for channel and volume +/- keys
Use standard definitions for channel controls, as defined at:
	http://linuxtv.org/wiki/index.php/Remote_Controllers

While here, fix a few broken up/down/left/right mappings

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:31 -03:00
Mauro Carvalho Chehab f545cb4394 V4L/DVB (12565): ir-keymaps: standardize timeshift key
Each remote were using a different keycode for timeshift. Use the same
keycode for all of them, using the map as defined at:
	http://linuxtv.org/wiki/index.php/Remote_Controllers

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:29 -03:00
Mauro Carvalho Chehab 62f1aa9f98 V4L/DVB (12564): ir-keymaps: Replace most KEY_[A-Z] to the proper definitions
There are several IR's that were using IR to type a letter that it is
known by some random application. Instead, the better is to use
the standard definitions found at:
	http://linuxtv.org/wiki/index.php/Remote_Controllers

And, if needed, submit a patch for the application to understand the
media keys.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:29 -03:00
Mauro Carvalho Chehab 7f9d691361 V4L/DVB (12563): ir-keymaps: add a link to the IR standard layout page
While we're still discussing it, let's point to the wiki page. In
the future, this should be added at V4L2 API spec DocBooks.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:28 -03:00
Mauro Carvalho Chehab 88d25a1ee4 V4L/DVB (12562): ir-keymaps: replace KEY_KP[0-9] to KEY_[0-9]
This is needed to match the standard mapping defined at:
	http://linuxtv.org/wiki/index.php/Remote_Controllers#Remote_Controllers

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:27 -03:00
Mauro Carvalho Chehab a83520f432 V4L/DVB (12560): Fix a number of EXPORT_SYMBOL warnings
Make Checkpatch tool happy:

-:2349: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable

On all cases, it were just a blank line at the wrong place. Yet, fixing it is trivial

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:27 -03:00
Mauro Carvalho Chehab 5d35364e31 V4L/DVB (12559): Properly indent comments with tabs
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:26 -03:00
Mauro Carvalho Chehab 3b82bddb15 V4L/DVB (12558): CodingStyle: Use [0x0f] instead of [ 0x0f ]
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:24 -03:00
Mauro Carvalho Chehab 97fd4f7fb6 V4L/DVB (12557): Use C99 comment CodingStyle
The ir-keymaps.c has frequent additions. As people tend to copy an old
keyboard entry, a bad CodingStyle at an ancient entry may result on a
freshly bad CodingStyle patch.

So, better to fix the CodingStyle for the entire file.

This patch is the first of a series of patches fixing it, generated by
some perl magic plus manual handling.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:24 -03:00
Hans Verkuil 9c9dbedf39 V4L/DVB (12553): FM TX: si4713: Add Kconfig and Makefile entries
Simply add Makefile and Kconfig entries.

[hverkuil@xs4all.nl: auto-select I2C_SI4713]
Signed-off-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:22 -03:00
Eduardo Valentin 02bee89e79 V4L/DVB (12552): FM TX: si4713: Add files to handle si4713 i2c device
This patch adds files to control si4713 devices.
Internal functions to control device properties
and initialization procedures are into these files.
Also, a v4l2 subdev interface is also exported.
This way other drivers can use this as v4l2 i2c subdevice.

Signed-off-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:20 -03:00
Eduardo Valentin 1fd2121c08 V4L/DVB (12551): FM TX: si4713: Add files to add radio interface for si4713
This patch adds files which creates the radio interface
for si4713 FM transmitter (modulator) devices.

In order to do the real access to device registers, this
driver uses the v4l2 subdev interface exported by si4713 i2c driver.

Signed-off-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:19 -03:00
Eduardo Valentin fdf82dc2e2 V4L/DVB (12549): v4l2: video device: Add FM TX controls default configurations
This patch adds basic configurations for FM TX extended controls.
That includes controls names, menu strings, pointer identification,
type classification and flags configuration.

Signed-off-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:19 -03:00
Hans Verkuil 6b5a9492ca V4L/DVB (12543): v4l: introduce string control support.
The upcoming RDS encoder needs support for string controls. This patch
implements the core implementation.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:17 -03:00
hermann pitton a138ebcf82 V4L/DVB (12492): saa7134-input: don't probe for the Pinnacle remotes anymore
With the recent improvements we don't need to probe anymore, if we know
the i2c address of the receiver.

The address of the receiver for the remote with the gray buttons is not
confirmed anywhere, but it is very unlikely to see it on something else.

We want to have that information anyway.

BTW, those remaining still probing, please join.

Signed-off-by: hermann pitton <hermann-pitton@arcor.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:15 -03:00
Oliver Neukum 821c777080 V4L/DVB (12491): remove unnecessary power management primitive in stk-webcam
This patch removes an unneeded power management primitive.
Power management is automatically enabled as probe ends.

Signed-off-by: Oliver Neukum <oliver@neukum.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:14 -03:00
Oldřich Jedlička 7b54360293 V4L/DVB (12490): Report only 32kHz for ALSA
There are several reasons:

 - SAA7133/35 uses DDEP (DemDec Easy Programming mode), which works in 32kHz
   only
 - SAA7134 for TV mode uses DemDec mode (32kHz)
 - Radio works in 32kHz only
 - When recording 48kHz from Line1/Line2, switching of capture source to TV
   means switching to 32kHz without any frequency translation

Signed-off-by: Oldřich Jedlička <oldium.pro@seznam.cz>
Acked-by: hermann pitton <hermann-pitton@arcor.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:13 -03:00
Dmitry Torokhov 89dec01b7e V4L/DVB (12489): pwc - fix few use-after-free and memory leaks
I just happen to peek inside the PWC driver and did not like what I saw
there. Please consider applying the patch below.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:13 -03:00
Dmitri Belimov 35c3057bb7 V4L/DVB (12488): Add RDS config for BeholdTV cards
Add config of RDS part for the BeholdTV tuners.

Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:12 -03:00
Dmitri Belimov 7ae2688963 V4L/DVB (12487): Fix control AC-3 of the 6752HS
Fix error for AC-3 control of the 6752HS MPEG-2 coder.

Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:11 -03:00
Igor M. Liplianin ad5f74c0ad V4L/DVB (12486): cx88: fix TBS 8920 card support
It does matter to set explicitly gpio0 value in
cx88_board structure for TBS 8920 card.

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:09 -03:00
Aleksandr V. Piskunov decee2e8a9 V4L/DVB (12485): zl10353: correct implementation of FE_READ_UNCORRECTED_BLOCKS
Makes zl10353 a bit more DVB API compliant:
FE_READ_UNCORRECTED_BLOCKS - keep a counter of UNC blocks
FE_GET_FRONTEND - return last set frequency instead of zero

Signed-off-by: Aleksandr V. Piskunov <alexandr.v.piskunov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:09 -03:00
Julia Lawall 75b697f747 V4L/DVB (12483): Use DIV_ROUND_CLOSEST
The kernel.h macro DIV_ROUND_CLOSEST performs the computation (x + d/2)/d
but is perhaps more readable.

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

// <smpl>
@haskernel@
@@

@depends on haskernel@
expression x,__divisor;
@@

- (((x) + ((__divisor) / 2)) / (__divisor))
+ DIV_ROUND_CLOSEST(x,__divisor)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:08 -03:00
Henrik Kurelid 166987c698 V4L/DVB (12482): firedtv: add PID filtering for SW zigzag retune
The AVC protocol uses the same command for tuning and PID filtering and
since dvb-core uses a software zigzagging to do automatic retuning this
could cause all PID filters to be cleared.  PID filter information is
now included in all DSD commands to the card.

Background:

There is a problem in the firedtv driver that causes recordings to stop
if the SW zigzag algorithm in dvb-core kicks in with a retune after the
application has set up the PID filters.  Since tuning and setting PID
filters uses the same AVC command (DSD) and only the replace subfunction
is supported by the card, it is not possible to do a retune without
setting the PID filters.  This means that the PID filtering has to be
sent in each tune.

This problem applies to C and T cards since S and S2 cards tune using a
vendor specific command.  The patch corrects the problem by sending the
PID list in each tune.  I have tested it on my T card with a good
result.

How to trigger problem:  Zap to a channel and output AV to a file, e.g.
"tzap -c channels.conf SVT1 -r -o SVT1.ts".  After a short while, pull
the antenna cable from the card.  The lock on the channel will disappear
and the TS file will stop increasing in size. Wait a couple of seconds.
Replug the cable again.  You will get a lock on the channel again, but
the TS file will never increase in size agains sinze no PIDS are
filtered.

Tested with kaffeine with DVB-T and DVB-C:  Fixes retuning after antenna
was plugged out and back in with DVB-T.  Does not fix this with DVB-C,
but also doesn't regress on DVB-C.

Signed-off-by: Henrik Kurelid <henrik@kurelid.se>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:08 -03:00
Julian Scheel 114323ede9 V4L/DVB (12481): Fix lowband tuning with tda8261
Attached is a patch which fixes tuning to low frequency channels with
stb0899+tda8261 cards like the KNC TV-Station DVB-S2.
The cause of the issue was a broken if construct, which should have been
an if/else if, so that the setting for the lowest matching frequency is
applied.

Without this patch for example tuning to "arte" on Astra 19.2, 10744MHz
SR22000 failed most times and when it failed the communication between
driver and tda8261 was completely broken.
This problem disappears with the attached patch.

Signed-off-by: Julian Scheel <julian@jusst.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:07 -03:00
Mart Raudsepp c92f056308 V4L/DVB: af9015: add new USB ID for KWorld PlusTV Dual DVB-T Stick (DVB-T 399U)
Add new USB ID (1b80:e400) for KWorld PlusTV Dual DVB-T Stick (DVB-T 399U).
The model number on the devices sticker label is "KW-DVB-T 399UR".

Signed-off-by: Mart Raudsepp <mart.raudsepp@artecdesign.ee>
Acked-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:06 -03:00
Mauro Carvalho Chehab d6f76b979c V4L/DVB (12478): ARRAY_SIZE changes
These changes were a direct result of using a semantic patch
More information can be found at http://www.emn.fr/x-info/coccinelle/

[mchehab@redhat.com: fix a merge conflict]
Signed-off-by: Stoyan Gaydarov <sgayda2@uiuc.edu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:05 -03:00
Julia Lawall 3227c860b6 V4L/DVB (12477): Use dst_type field instead of type_flags
It seems from other code that it is the dst_type field rather than the
type_flags field that contains values of the form DST_TYPE_IS...
The type_flags field contains values of the form DST_TYPE_HAS...

The semantic match that finds this problem is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@@ struct dst_state E; @@

(
*E.type_flags ==
  \( DST_TYPE_IS_SAT\|DST_TYPE_IS_TERR\|DST_TYPE_IS_CABLE\|DST_TYPE_IS_ATSC \)
|
*E.type_flags !=
  \( DST_TYPE_IS_SAT\|DST_TYPE_IS_TERR\|DST_TYPE_IS_CABLE\|DST_TYPE_IS_ATSC \)
)
// </smpl>

Cc: Manu Abraham <abraham.manu@gmail.com>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:03 -03:00
Nam Phạm Thành ce212f052f V4L/DVB (12475): Add support for Humax/Coex DVB-T USB Stick 2.0 High Speed
This patch adds support for Humax/Coex DVB-T USB Stick 2.0 High Speed
which is a very popular tuner sold in Vietnam.
Tested with at least 3 tuners.

Cc: Patrick Boettcher <pboettcher@kernellabs.com>
Signed-off-by: Pham Thanh Nam <phamthanhnam.ptn@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:03 -03:00
Mauro Carvalho Chehab 1c2ca35294 V4L/DVB (12472): hdpvr-control: fix bad whitespaces
It were using 7 spaces instead of tab for indent.

Cc: Janne Grunau <j@jannau.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:02 -03:00
Mauro Carvalho Chehab 272ece5e79 V4L/DVB (12471): stv06xx: fix bad whitespaces
It were using 7 spaces instead of tab for indent.

Cc: Erik Andren <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:01 -03:00
Mauro Carvalho Chehab 8ccd4cd07e V4L/DVB (12470): cx231xx/cx231xx-conf-reg.h: fix bad whitespaces
It were using 7 spaces instead of tab for indent.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:01 -03:00
Mauro Carvalho Chehab dfb4ba1e13 V4L/DVB (12468): saa7134: Fix bad whitespacing
The changeset 0b17d0ed that aded ASUSTeK P7131 Analog were using
7 spaces instead of tab, probably due to some bad cut-and-paste.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:19:00 -03:00
Mauro Carvalho Chehab b24ed7b662 V4L/DVB (12466): Kconfig files: Fix improper use of whitespaces
On VIDEO_M52790 and USB_GSPCA_SN9C20X, instead of tab, it were
using 7 whitespaces at the beginning, probably due to some
cut-and-paste trouble.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:59 -03:00
Andrzej Hajda 3c1c48bbcf V4L/DVB (12465): cx88: High resolution timer for Remote Controls
Patch solves problem of missed keystrokes on some remote controls,
as reported on http://bugzilla.kernel.org/show_bug.cgi?id=9637 .

Signed-off-by: Andrzej Hajda <andrzej.hajda@wp.pl>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:58 -03:00
Igor M. Liplianin ecfcfec804 V4L/DVB (12463): Add support for Compro VideoMate S350 DVB-S PCI card.
Add Compro VideoMate S350 DVB-S driver.
The card uses zl10313, zl10039, saa7130 integrated circuits.

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:57 -03:00
Igor M. Liplianin d0a1ddad1c V4L/DVB (12462): Add TeVii S630 USB DVB-S card support.
The card includes Intel ce5039(Zarlink zl10039) tuner
and Intel ce6313 (Zarlink zl10313) demod.

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:56 -03:00
Igor M. Liplianin 2ccf5a9906 V4L/DVB (12461): Add ce5039(zl10039) tuner support.
The code from Jan D. Louw with some minor changes.
http://article.gmane.org/gmane.linux.drivers.dvb/38163
Tested with TeVii S630 DVB-S USB card by me (Igor)

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:55 -03:00
Theodore Kilgore 3040b04342 V4L/DVB (12459): gspca - jeilinj: New subdriver for Jeilin chip.
Signed-off-by: Theodore Kilgore <kilgota@auburn.edu>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:54 -03:00
Hans Verkuil 9d7530d53d V4L/DVB (12455): radio-typhoon: remove obsolete RADIO_TYPHOON_PROC_FS config option
Thanks to Robert P.J. Day for finding this.

Thanks-to: Robert P.J. Day <rpjday@crashcourse.ca>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:53 -03:00
Mauro Carvalho Chehab 17d8dfe8c8 V4L/DVB (12452): gspca/Kconfig: Fix bad identation for USB_GSPCA_SN9C20X_EVDEV
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:53 -03:00
Devin Heitmueller 8cd9aaefad V4L/DVB (12444): em28xx: add support for Terratec Cinergy Hybrid T USB XS remote control
Add support for the remote control that comes with the Cinergy Hybrid T USB XS

Thanks to Jelle de Jong for providing sample hardware to test with.

Cc: Jelle de Jong <jelledejong@powercraft.nl>
Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:52 -03:00
Vlastimil Labsky 4d14c833c0 V4L/DVB (12439): cx88: add support for WinFast DTV2000H rev. J
I updated and simplyfied patch from Zbynek Hrabovsky for recent kernel.
It enables autodetection of card, sound in analog TV , sound in FM radio
and switching between antenna and cable RF input.  Radio tuner still
doesn't work, I don't even know how it works.  Some guys wrote me that FM
radio works with TV tuner used instead of radio part (symlink video0 ->
radio0).

Cc: Gerd Knorr <kraxel@bytesex.org>
Signed-off-by: Vlastimil Labsky <vlasta.labsky@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:50 -03:00
Roel Kluin bd0eb12f61 V4L/DVB (12435): strlcpy() will always null terminate the string.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:50 -03:00
Douglas Schilling Landgraf a35c87c708 V4L/DVB (12434): em28xx: fix empire auto-detect
Fixed eeprom hash table

Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:49 -03:00
Hans Verkuil eb2de30b31 V4L/DVB (12427): cx24113: fix mips compiler warning
do_div requires an u64 as the first argument, not a s64.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Acked-by: Patrick Boettcher <pboettcher@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:49 -03:00
Hans Verkuil f19b56a8eb V4L/DVB (12426): pvrusb2: fix compile warning
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:49 -03:00
David T.L. Wong 6bf1a997ed V4L/DVB (12423): cxusb, d680 dmbth use unified lgs8gxx code instead of lgs8gl5
Use unified lgs8gxx frontend instead of reverse engineered lgs8gl5 frontend.
After this patch, lgs8gl5 frontend could be mark as deprecated.
Future development should base on unified lgs8gxx frontend.

Signed-off-by: David T.L. Wong <davidtlwong@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:47 -03:00
Julia Lawall b807d17555 V4L/DVB (12421): drivers/media/video/gspca: introduce missing kfree
Error handling code following a kmalloc should free the allocated data.

Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:46 -03:00
hermann pitton 46058128ff V4L/DVB (12420): saa7134: fix the radio on Avermedia GO 007 FM
We have support for radio on saa7133/35/31e cards with tda8290/8275(a)
and 5.5MHz ceramic filter on the bridge chips since a while.

It was previously not tested, if this card supports it too, but the old
"ghost" radio with wrong filters doesn't work anymore.

Thanks go to Pham Thanh Nam and Laszlo Kustan for reporting it working
on that input.

Signed-off-by: hermann pitton <hermann-pitton@arcor.de>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:45 -03:00
Beholder Intl. Ltd. Dmitry Belimov 4786dd65fc V4L/DVB (12419): Fix incorrect type of tuner for the BeholdTV H6 card
Define correct tuner in config. Radio now works fine

Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:44 -03:00
Tobias Lorenz 9dcb79c2ee V4L/DVB (12417): I2C cleanups and version checks
The structure and comments of the I2C part have been adopted to fit to the
USB part.

Some additional cleanups and precisements have been made to the version
detection and checking functionality to clearly separate HW/SW/FW version.

Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:43 -03:00
Joonyoung Shim cc35bbddfe V4L/DVB (12416): radio-si470x: add i2c driver for si470x
This patch supports i2c interface of si470x. The i2c specific part
exists in radio-si470x-i2c.c file and the common part uses
radio-si470x-common.c file. The '#if defined' is inserted inevitably
because of parts used only si470x usb in the common file.

The current driver version doesn't support the RDS.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:43 -03:00
Joonyoung Shim 3c7cc8d52c V4L/DVB (12415): radio-si470x: add disconnect check function
The si470x_disconnect_check is function to check disconnect state of
radio in common file. The function is implemented in each interface
file.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:42 -03:00
Joonyoung Shim a9d6fd5e31 V4L/DVB (12414): radio-si470x: change to dev_* macro from printk
This patch is for using dev_* macro instead of printk.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:40 -03:00
Joonyoung Shim b09cd16354 V4L/DVB (12413): radio-si470x: separate common and usb code
This patch is a preceding work to add the i2c interface of si470x.
The si470x directory includes a common file and usb specific file and
header file.
The part unrelated with usb interface and i2c interface exists in
radio-si470x-common.c file, and The usb specific part exists in
radio-si470x-usb.c file.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
[tobias.lorenz@gmx.net: Small changes, due to new include "linux/smp_lock.h"]
Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:40 -03:00
Mauro Carvalho Chehab 4efa2d75d4 V4L/DVB (12408): em28xx: Implement g/s_register via address match
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:37 -03:00
Pete Hildebrandt c53d83ccc8 V4L/DVB (12396): [patch] Added Support for STK7700D (DVB)
This patch adds support for the STK7700D USB-DVB-Device.

lsusb identifies it as:
idVendor           0x1164 YUAN High-Tech Development Co., Ltd
idProduct          0x1efc
 iProduct                2 STK7700D

The device is build into a Samsung R55-T5500 notebook.

Signed-off-by: Pete Hildebrandt <send2ph@googlemail.com>
Signed-off-by: Patrick Boettcher <pboettcher@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:36 -03:00
Eberhard Mattes 0b0157398e V4L/DVB (12388): dvb-usb: fix tuning with Cinergy T2
cinergyInitialize param.flags.

Signed-off-by: Eberhard Mattes <eberhard.mattes@web.de>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:35 -03:00
Jean-Francois Moine bb2c818fae V4L/DVB (12383): gspca - vc032x: Bad h/v flip controls when inverted by default.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:34 -03:00
Marton Nemeth d40a1da2b4 V4L/DVB (12382): gspca - main: Remove vidioc_s_std().
The vidioc_s_std() is not necessary when vdev->tvnorms == 0.

Signed-off-by: Marton Nemeth <nm127@freemail.hu>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:34 -03:00
Laurent Pinchart 8e113595ed V4L/DVB (12379): uvcvideo: Multiple streaming interfaces support
Restructure the UVC descriptors parsing code to handle multiple streaming
interfaces. The driver now creates a uvc_video_chain instance for each chain
detected in the UVC control interface descriptors, and tries to register one
video device per streaming endpoint.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:33 -03:00
Laurent Pinchart 35f02a681b V4L/DVB (12378): uvcvideo: Restructure the driver to support multiple simultaneous streams.
As a first step towards multiple streaming interfaces support, reorganize the
driver's data structures to cleanly separate video control and video streaming
data.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:32 -03:00
Mauro Carvalho Chehab 6c428b578b V4L/DVB (12376): em28xx: fix V4L2 API compliance: don't expose audio inputs for devices without it
V4L2 API (chapter 1.5) states that:

	Drivers must implement all input ioctls when the device has one
	or more inputs, all output ioctls when the device has one or more outputs.
	When the device has any audio inputs or outputs the driver must set the
	V4L2_CAP_AUDIO flag in the struct v4l2_capability returned by the
	VIDIOC_QUERYCAP ioctl.

So, devices without audio input should return -EINVAL.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:31 -03:00
Jiri Slaby 00c1e2167e V4L/DVB (12373): hdpvr: fix lock imbalances
There are many lock imbalances in this driver. Fix all found.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:30 -03:00
Jiri Slaby b9ab3508ef V4L/DVB (12372): saa7134: fix lock imbalance
There seems to be one superfluos unlock in a poll function. Remove it.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:29 -03:00
Oliver Neukum 085575a325 V4L/DVB (12369): stv680: kfree called before usb_kill_urb
The irq handler will touch memory. Even in the error case some URBs may
complete. Thus no memory must be kfreed before all URBs are killed.

Signed-off-by: Oliver Neukum <oliver@neukum.org>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:28 -03:00
Andy Walls f5d887ae60 V4L/DVB (12368): ir-kbd-i2c: Add support for Z8F0811/Hauppage IR transceivers
This patch adds support for Zilog Z8F0811 IR transceiver chips on
CX2341[68] based boards to ir-kbd-i2c for both the old i2c binding model
and the new i2c binding model.

Signed-off-by: Andy Walls <awalls@radix.net>
Reviewed-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:27 -03:00
Andy Walls 8ca955689a V4L/DVB (12367): cx18: Add i2c initialization for Z8F0811/Hauppage IR transceivers
This patch add support to the cx18 driver for setting up the
Z8F0811/Hauppauge IR Tx/Rx chip with the i2c binding model in newer
kernels.

Signed-off-by: Andy Walls <awalls@radix.net>
Reviewed-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:25 -03:00
Andy Walls 1b6e59e3f4 V4L/DVB (12366): ir-kbd-i2c: Allow use of ir-kdb-i2c internal get_key funcs and set ir_type
This patch augments the init data passed by bridge drivers to
ir-kbd-i2c, so that the ir_type can be set explicitly, and so
ir-kbd-i2c internal get_key functions can be reused without
requiring symbols from ir-kbd-i2c in the bridge driver.

Signed-off-by: Andy Walls <awalls@radix.net>
Reviewed-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:25 -03:00
Jean Delvare 157da2762c V4L/DVB (12365): ir-kbd-i2c: Remove superfulous inlines
Functions which are referenced by their address can't be inlined by
definition.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:24 -03:00
Michael Krufky 5376176199 V4L/DVB (12360): au0828: fix typo: dvb uses bulk xfer, dont say isoc in debug
The au0828-dvb driver uses bulk usb transfers for digital transport,
but the debug reports, "iso xfer already running!\n".

Fix this to report bulk instead of isoc.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:23 -03:00
Jean-Francois Moine 1c8336d338 V4L/DVB (12358): gspca - main: Memorize the current alt before setting it
This prevents a loop if a permanent error occurs in usb_set_interface().

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:22 -03:00
Hans de Goede c61fd24f2d V4L/DVB (12357): gspca - tv8532: Bad ISOC packet scan
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>
2009-09-12 12:18:20 -03:00
Denis Loginov 6baefab531 V4L/DVB (12356): gspca - sonixj: Webcam 0c45:6148 added
Signed-off-by: Denis Loginov <dinvlad@gmail.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:19 -03:00
Jean-Francois Moine 8b605f1810 V4L/DVB (12355): gspca - vc032x: Cleanup source
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:19 -03:00
Jean-Francois Moine e27188ee6b V4L/DVB (12354): gspca - vc032x: H and V flip controls added for mi13x0_soc sensors
Also, H/V flip default values adjusted according to the webcam IDs.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:19 -03:00
Jean-Francois Moine 111815ef7e V4L/DVB (12353): gspca - vc032x: Add the 1280x960 resolution for sensor mi1310_soc
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:18 -03:00
AceLan Kao 4041f6b3b4 V4L/DVB (12352): gspca - vc032x: Fix mi1310_soc preview and LED
The patches
	gspca - vc032x: Add resolution 1280x1024 for sensor mi1310_soc.
	gspca - vc032x: Webcam 041e:405b added and mi1310_soc updated.
will make the preview function not work, so I disable the 1280x1024 resolution
and revert back to the origin mi1310_soc settings.
And, using USB snoop tool on Windows to get the correct i2c commands to
turn on/off the LED flash.

Signed-off-by: AceLan Kao <acelan.kao@canonical.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:17 -03:00
Brian Johnson 00b581ef0d V4L/DVB (12351): gspca - sn9c20x: Misc fixes
* use i2c_w instead of reg_w
* return error on failure
* read the correct number of bytes

Signed-off-by: Brian Johnson <brijohn@gmail.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:16 -03:00
Steven Toth f3d6f63302 V4L/DVB (12347): cx25840: Bugfix for no DVB-T on the Hauppauge HVR-1700
After the i2c subdev changes the ordering of initialization changed,
causing a total loss of previous GPIO settings and a loss of DTV.
The generic firmware loading routine has now changed to preserve
GPIO values if the device is cx23885 based (safety) and I've
moved the GPIO configuration from probe() into the cx23885 init
func which is a little clearer and fixes the bug.

Tested-by: Sohail Syyed <linuxtv@hubstar.net>
Reviewed-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:15 -03:00
Mauro Carvalho Chehab 73c6f462d1 V4L/DVB (12345): em28xx: fix audio VIDIOC_S_CTRL adjustments on devices without ac97
Even devices without ac97 needs to call analog audio setup function, to
properly set xclk and mute/unmute.

Thanks to Angelo Cano <acano@fastmail.fm> for reporting and testing it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:14 -03:00
Jean Delvare e81516c58e V4L/DVB (12343): Stop defining I2C adapter IDs nobody uses
There is no point in defining I2C adapter IDs when no code is using
them. As this field might go away in the future, stop using it when
we don't need to.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:13 -03:00
Jan Nikitenko 43f8de7ac6 V4L/DVB (12342): af9015: avoid magically sized temporary buffer in eeprom_dump
Replace printing to magically sized temporary buffer with use
of KERN_CONT for continual printing of eeprom registers dump.

Since deb_info is defined as dprintk, which is conditionally defined
to printk without additional parameters, meaning that deb_info is equivalent
to direct printk (without adding KERN_ facility), we can use KERN_DEBUG and
KERN_CONT in there, eliminating the need for sprintf into temporary buffer
with not easily readable/magical size.

Though it's strange, that deb_info definition uses printk without KERN_
facility and callers don't use it either.

Signed-off-by: Jan Nikitenko <jan.nikitenko@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:13 -03:00
Andy Walls 1420d498fd V4L/DVB (12336): ivtv: Fix improper GPIO audio mux input switch on video standard change
Remove the subdev_s_std() method from the GPIO subdev.  It appears it was
used in the past to effect the switch back from radio mode to tuner mode,
but it had a side effect that is improper and against the V4L2 spec, when
you were not in radio mode.  Whenever the video stanadrd was changed, the
GPIO audio mux was set back to the tuner audio input, even if you were set
to a Line In input.

Thanks to Ravi A. for doing the troubleshooting to point me right to the
problem.

Reported-by: Ravi A <asvravi@gmail.com>
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:12 -03:00
Andy Walls d31b67d81b V4L/DVB (12335): ivtv: Fix errors in AVerTV M113 card definitions and add a new M113 card
Tested-by: Ravi A. <asvravi@gmail.com>
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:11 -03:00
Andy Walls e3e1920b28 V4L/DVB (12334): tuner-simple: Add an entry for the Partsnic PTI-5NF05 NTSC tuner
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:10 -03:00
Igor M. Liplianin d8300df9fb V4L/DVB (12332): Create card parameters array in SDMC DM1105 driver
Create card parameters array in SDMC DM1105 driver.
It is useful for cards with the same pci id, but different
tuners, lnb power control circuits, etc.

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:09 -03:00
Laurent Pinchart bab6f66c08 V4L/DVB (12327): uvcvideo: Add PROBE_DEF quirk and enable it for the MT6227 device
At least one MT6227 model crashes when receiving a GET_DEF request on the
video probe control. As the various models can't be told apart based on the
descriptors, add a PROBE_DEF quirk to avoid sending the GET_DEF request and
enable the quirk for all models.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:09 -03:00
Lamarque Vieira Souza 76594c5315 V4L/DVB (12326): zr364xx: error message when buffer is too small and code cleanup
. added code to print an error message when buffer is too small to hold frame
data, that is better than just a hard crash. Tested using MAX_FRAME_SIZE =
50000, lots of error messages appeared in /var/log/messages but no crash.

. removed line "f->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;" in
zr364xx_vidioc_try_fmt_vid_cap, it should not be there.

. changes to improve performance (or at least not hurt it): removed some
unneeded debug messages; added macro FULL_DEBUG to enable debug messages in
performance critical places, this macro is disabled by default; removed "if
(frm->lpvbits == NULL)..." in zr364xx_read_video_callback because after
analisying the source code I concluded it will always results to false, so it
is not needed.

. some small code reorganization.

Signed-off-by: Lamarque V. Souza <lamarque@gmail.com>
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:07 -03:00
Lamarque Vieira Souza 8c5f32ac2f V4L/DVB (12325): Implement changing resolution on the fly for zr364xx driver
This patch implements changing resolution in zr364xx_vidioc_s_fmt_vid_cap for
zr364xx driver. This version is synced with v4l-dvb as of 20/Jul/2009. Tested
with Creative PC-CAM 880.

OBS: I had to increase MAX_FRAME_SIZE to prevent a hard crash in my notebook
(caps lock blinking) when testing with mplayer, which automatically sets
resolution to the maximum (640x480). Maybe we should add code to auto-detect
frame size to prevent this kind of crash in the future.

Signed-off-by: Lamarque V. Souza <lamarque@gmail.com>
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:06 -03:00
Igor M. Liplianin 8db6d633be V4L/DVB (12314): cx23885: add CAM presence checkout
Add CAM presence checkout during CiMax init for NetUP card.

CAM presence checkout is needed after power on PC.

Signed-off-by: Igor M. Liplianin <liplianin@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:04 -03:00
Igor M. Liplianin c846121058 V4L/DVB (12313): stv6110: Read registers through one time i2c_transfer calling
Signed-off-by: Igor M. Liplianin <liplianin@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:03 -03:00
Abylay Ospan fc7e4a3e72 V4L/DVB (12312): stv0900: fix i2c repeater configuration must be set to manual
In automatic mode every stop event on SDA line ends repetition.
However, in  NetUP Dual card on the same i2c bus we have several devices.
If someone using both adapters to lock simultaneously or working with CAM interface
during lock procedure, it lead to end repetition prematurely quite often.
Set stv0900 i2c repeater to manual mode prevents such situation.

Signed-off-by: Abylay Ospan <aospan@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:03 -03:00
Abylay Ospan 644c7ef0b9 V4L/DVB (12311): Change clocking configuration and frequency for NetUP card.
Signed-off-by: Abylay Ospan <aospan@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:02 -03:00
Igor M. Liplianin ee5e7d94c9 V4L/DVB (12310): stv6110 tuner: remove unused iq_wiring configuration parameter.
Signed-off-by: Igor M. Liplianin <liplianin@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:02 -03:00
Igor M. Liplianin 92782bb003 V4L/DVB (12309): Add output clock configuration for stv6110 tuner.
Signed-off-by: Igor M. Liplianin <liplianin@netup.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:18:00 -03:00
Steven Toth 25ea66e269 V4L/DVB (12307): cx23885: Modify hardware revision detection for newer silicon
cx23885: Modify hardware revision detection for newer silicon

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:59 -03:00
Steven Toth 1369738023 V4L/DVB (12306): cx23885: Add support for ATSC/QAM on Hauppauge HVR-1850
cx23885: Add support for ATSC/QAM on Hauppauge HVR-1850

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:57 -03:00
Steven Toth 21ff3e4f63 V4L/DVB (12305): cx23885: Convert existing HVR1800 GPIO calls into new format
... improves readability and routes the calls through a specific single point.

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:54 -03:00
Steven Toth f659c513d5 V4L/DVB (12304): cx23885: Remove hardcoded gpio bits from the encoder driver
The encoder driver has hardcoded GPIO bits set for the HVR1800, regardless
of whether it's being used by a HVR1800 or not. I've implemented some generic
GPIO manipulation routines and I'm calling them only when appropriate.

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:53 -03:00
Trent Piepho 7a6fbd8337 V4L/DVB (12294): b2c2: Use dvb-pll for Cablestar2
The dvb-pll code should do the same thing that
alps_tdee4_stv0297_tuner_set_params() was doing.  Except the dvb-pll code
will check for tuner presence when attaching, while the old code didn't.

This tuner appears to not be behind the stv0297's I2C gate but is instead
on a different I2C adapter provided by the flexcop chip.  The old code
would turn the I2C gate off each time the tuner was used.  I've changed it
to turn the gate off when the tuner is attached and then disable the gate
control function.  This should result in the gate staying off, which should
be even better.

[hverkuil@xs4all.nl: fix compile error]

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:52 -03:00
Trent Piepho 016e53de0a V4L/DVB (12293): b2c2: Use dvb-pll for Skystar2 rev 2.3 and rev 2.6
The code in skystar23_samsung_tbdu18132_tuner_set_params() and
samsung_tbmu24112_tuner_set_params() is equivalent to what the dvb-pll code
does.  There could be an issue because the dvb-pll code will probe to check
for the tuner, while the previous code didn't do any checks.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:52 -03:00
Trent Piepho 6d67c9717b V4L/DVB (12292): b2c2: Use dvb-pll for AirStar DVB-T's tuner
The code in samsung_tdtc9251dh0_calc_regs() is equivalent to what dvb-pll's
code does.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:51 -03:00
Trent Piepho d799ce5708 V4L/DVB (12290): dvb-pll: Add support for Alps TDEE4 DVB-C NIM
No datasheet, data take from code in flexcop driver.  That code rounded
down the divisor rather than rounding to nearest, which was probably not
intentional and the dvb-pll code will round to nearest.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:50 -03:00
Trent Piepho 9d5d75a9eb V4L/DVB (12289): dvb-pll: Add support for Samsung TBMU24112 DVB-S NIM
Tuner parameters determined from code in flexcop driver.  That code rounded
the divisor down instead of to the nearest value.  This was probably not
intentional and the dvb-pll version will round to nearest.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:49 -03:00
Trent Piepho f52c48535f V4L/DVB (12288): dvb-pll: Add support for Samsung TBDU18132 DVB-S NIM
Tuner parameters taken from flexcop driver.  This PLL has a 17 bit divisor
while the dvb-pll driver is designed for 15 bit divisors.  It's not a
problem as 15 bits is enough for the tuner's entire range.  But if a larger
range was wanted, it could be done by adding additional bands with the
extra divisor bits appearing as band switch bits.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:48 -03:00
Trent Piepho a104ed073b V4L/DVB (12287): dvb-pll: Add Samsung TDTC9251DH0 DVB-T NIM
No datasheet, tuner data comes from code in flexcop driver.  This tuner is
also used on the AVerTV 771 supported by the bttv driver, but that code
uses a different tuner configuration, which is surprising.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:48 -03:00
Johannes Goerner af5f88c877 V4L/DVB (12281): gspca - sunplus: Webcam 052b:1803 added.
Signed-off-by: Johannes Goerner <johannes-goerner@gmx.de>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:47 -03:00
Jean-Francois Moine d8f400efc1 V4L/DVB (12280): gspca - sonixj: Remove auto gain/wb/expo for the ov7660 sensor.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:46 -03:00
Lamarque Vieira Souza ccbf035ae5 V4L/DVB (12278): zr364xx: implement V4L2_CAP_STREAMING
This patch implements V4L2_CAP_STREAMING for the zr364xx driver, by
converting the driver to use videobuf. This version is synced with v4l-dvb as
of 15/Jul/2009.

Tested with Creative PC-CAM 880.

It basically:
. implements V4L2_CAP_STREAMING using videobuf;

. re-implements V4L2_CAP_READWRITE using videobuf;

. copies cam->udev->product to the card field of the v4l2_capability struct.
That gives more information to the users about the webcam;

. moves the brightness setting code from before requesting a frame (in
read_frame) to the vidioc_s_ctrl ioctl. This way the brightness code is
executed only when the application requests a change in brightness and
not before every frame read;

. comments part of zr364xx_vidioc_try_fmt_vid_cap that says that Skype +
libv4l do not work.

This patch fixes zr364xx for applications such as mplayer,
Kopete+libv4l and Skype+libv4l can make use of the webcam that comes
with zr364xx chip.

Signed-off-by: Lamarque V. Souza <lamarque@gmail.com>
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
[mchehab@redhat.com: fix the lack of linux/version.h]
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:44 -03:00
Andreas Oberritter a4afd65870 V4L/DVB (12276): Remove a useless check from dvb_dmx_swfilter_packet()
Values for 'pid' range from 0 to 0x1fff. Therefore 'feed->pid' can never
be equal to both 'pid' and 0x2000. This makes the continue statement have
no effect.

Signed-off-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:44 -03:00
Andreas Oberritter 1cb662a314 V4L/DVB (12275): Add two new ioctls: DMX_ADD_PID and DMX_REMOVE_PID
DMX_ADD_PID allows to add multiple PIDs to a transport stream filter
previously set up with DMX_SET_PES_FILTER and output=DMX_OUT_TSDEMUX_TAP.

DMX_REMOVE_PID is used to drop a PID from a filter.

These ioctls are to be used by readers of /dev/dvb/adapterX/demuxY. They
may be called at any time, i.e. before or after the first filter on the
shared file descriptor was started.

They make it possible to record multiple services without the need to de-
or re-multiplex TS packets.

To accomplish this, dmxdev_filter->feed.ts has been converted to a list
of struct dmxdev_feeds, each containing a PID value and a pointer to a
struct dmx_ts_feed.

Signed-off-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:43 -03:00
Mauro Carvalho Chehab a98f6af96e V4L/DVB (12274): em28xx-video: better implement ac97 control ioctls
In the past, some devices with saa711x had their parameters controlled
directly inside em28xx driver, instead of using their proper module for
it.

Due to that, the ac97 controls were mixed with saa711x ones.

Older patches removed all saa711x controls, but we still need to control
ac97 devices on em28xx, since we don't have a separate v4l2 device for
it.

The proper way to address is to create a separate ac97 v4l2 device.
While we don't have it, we should clean up the code to allow having a
better view of what is part of em28xx core code and what's due to ac97
control inside it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:42 -03:00
Mauro Carvalho Chehab ed10daaeb3 V4L/DVB (12273): em28xx-video: rename ac97 audio controls to better document it
As em28xx chip has nothing to do with volume/mute controls, rename those
controls to properly indicate that they control the companion AC97 chip
that it is inside the boards with this chip.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:41 -03:00
David Wong 2365b2d307 V4L/DVB (12272): cx23885: add card Magic-Pro ProHDTV Extreme 2
cx23885: add card Magic-Pro  ProHDTV Extreme 2 PCI-E.

Signed-off-by: David T.L. Wong <davidtlwong@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:39 -03:00
David Wong b80dc1c673 V4L/DVB (12271): lgs8gxx: add lgs8g75 support
lgs8gxx: add lgs8g75 demodulator support

Signed-off-by: David T.L. Wong <davidtlwong@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:38 -03:00
Jean-Francois Moine a0d64456f7 V4L/DVB (12231): gspca - main: Version change.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:37 -03:00
Jean-Francois Moine 78a6d74e81 V4L/DVB (12230): gspca - t613: Change tas5130a init sequences.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:37 -03:00
Jean-Francois Moine 1f53b0b010 V4L/DVB (12229): gspca - main: Change the ISOC initialization mechanism.
- call a new subdriver function 'isoc_init' before chosing the first
  alternate setting.
- call a new subdriver function 'isoc_nego' when submitting the URBs failed.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:37 -03:00
Jean-Francois Moine 1852e75a55 V4L/DVB (12228): gspca - vc032x: Webcam 0ac8:c301 added.
Only the back sensor (mi1320_soc) is usable.

Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:36 -03:00
Jean-Francois Moine 3eed782599 V4L/DVB (12227): gspca - pac7311: Webcam 093a:2629 added.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:34 -03:00
Jean-Francois Moine c4d363ccd7 V4L/DVB (12226): gspca - spca508: Extend the write_vector routine.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:33 -03:00
Hans Verkuil 43b786677e V4L/DVB (12218): radio-si470x: conform to the RDS spec.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:33 -03:00
Hans Verkuil 8e280f24d3 V4L/DVB (12217): radio-cadet: conform to the RDS spec.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:33 -03:00
Hans Verkuil f101a2a787 V4L/DVB (12216): saa7134: set RDS capability if applicable.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:32 -03:00
Hans Verkuil 3c86cf7a7d V4L/DVB (12215): saa6588: conform to the final RDS spec.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:31 -03:00
Hans Verkuil 6a052c8434 V4L/DVB (12214): bttv: set RDS capability if applicable.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:29 -03:00
Andy Walls 3bd10fc9f5 V4L/DVB (12210): ivtv: Fix automatic detection of AVerMedia UltraTV 1500MCE.
My initial change left the AVerMedia UtlraTV 1500MCE card entry out of the
list of cards to check during the probe.  This change adds it to the
ivtv_card_list[].

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:28 -03:00
Andy Walls 50364593f8 V4L/DVB (12209): ivtv: Add card entry for AVerMedia UltraTV 1500 MCE (M113 variant)
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:27 -03:00
Andy Walls 25a42e4d4a V4L/DVB (12207): cx18: Add an EEPROM dump routine for the Yuan MPC718 and future cards
Add a routine for dumping the EEPROM of the MPC718.  It is generic enough
to use for other cards in the future that may have an EEPROM.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:26 -03:00
Joe Perches 76e9741d1d V4L/DVB (12204): bttv and meye: Use PCI_VDEVICE
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:25 -03:00
Matthias Schwarzott 0389b34e7c V4L/DVB (12200): mt312: Fix checkpatch warnings
This patch fixes some checkpatch warnings in mt312-driver.

Signed-off-by: Matthias Schwarzott <zzam@gentoo.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:24 -03:00
Roel Kluin de81c3c3f5 V4L/DVB (12199): remove redundant tests on unsigned
input, inp and i are unsigned. When negative they are wrapped and caught by the
other test.

Cc: Andy Walls <awalls@radix.net>
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:23 -03:00
Joe Perches ce27cd3bf9 V4L/DVB (12198): ivtv-driver.c: Remove unnecessary semicolons
Cc: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:23 -03:00
Joe Perches 1ebcad7707 V4L/DVB (12197): Remove unnecessary semicolons
Cc: Patrick Boettcher <patrick.boettcher@desy.de>
Cc: Steven Toth <stoth@linuxtv.org>
Cc: Igor M. Liplianin <liplianin@netup.ru>
Cc: Srinivasa Deevi <srinivasa.deevi@conexant.com>
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:23 -03:00
Joe Perches 32a60955fb V4L/DVB (12196): cx18-fileops.c: Remove unnecessary semicolons
Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Andy Walls <awalls@radix.net>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:22 -03:00
Zhenyu Wang 7c8b56795f V4L/DVB (12190): em28xx: Add support for Gadmei UTV330+
em28xx: Add support for Gadmei UTV330+

Signed-off-by: Zhenyu Wang <zhen78@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:21 -03:00
Laurent Pinchart 5bdf137758 V4L/DVB (12188): uvcvideo: Set PROBE_MINMAX quirk for Aveo Technology webcams
Some Aveo Technology USB 2.0 Camera (1871:0306) revisions seem to require the
PROBE_MINMAX quirk. As the camera supports uncompressed YUYV data only, it's
safe to set the quirk even if not strictly required for all models. Update the
device entry in the device IDs list.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:20 -03:00
Laurent Pinchart de05f63430 V4L/DVB (12187): uvcvideo: Move UVC definitions to linux/usb/video.h
To make UVC constants accessible by a future UVC gadget driver, move them from
drivers/media/video/uvc/uvcvideo.h to include/linux/usb/video.h.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:19 -03:00
Laurent Pinchart 446a164b70 V4L/DVB (12186): uvcvideo: Remove unused Logitech-specific constants
Those constants are not used anymore, remove them.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:18 -03:00
Laurent Pinchart b482d9231a V4L/DVB (12185): uvcvideo: Prefix all UVC constants with UVC_
In preparation to moving UVC constants to a public location, prefix all
constants with UVC_ to avoid namespace clashes.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:18 -03:00
Laurent Pinchart 042e143e8b V4L/DVB (12184): uvcvideo: Use class-specific descriptor types from usb/ch9.h
uvcvideo.h redefines class-specific descriptor types already present in
usb/ch9.h. Remove the duplicated definitions and use the ones from usb/ch9.h.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:17 -03:00
Mauro Carvalho Chehab d33fbcbb21 V4L/DVB (12168): v4l2-ioctl: avoid flooding log with unasked debug messages
Thanks to Hans Verkuil <hverkuil@xs4all.nl> for pointing this issue on
my last patch.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:17 -03:00
Mauro Carvalho Chehab d1afe4250a V4L/DVB (12124): v4l2-ioctl: better output debug messages for VIDIOC_ENUM_FRAMESIZES
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:16 -03:00
Mauro Carvalho Chehab c85e46e348 V4L/DVB (12147): pwc: remove definitions that are already present at videodev2.h
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:13 -03:00
Tobias Lorenz fca9596b17 V4L/DVB (12144): radio-si470x: removed v4l2_queryctrl in favor of v4l2_ctrl_query_fill
Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:12 -03:00
Tobias Lorenz 9817dc3133 V4L/DVB (12143): radio-si470x: cleanups
- Remove user count log messages
- Comments adopted to general style

Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:11 -03:00
Tobias Lorenz 721f59ed61 V4L/DVB (12142): radio-si470x: Add suport for RDS endpoint interrupt mode
Add support for interrupt mode for RDS endpoint, instead of polling.
Improves RDS reception significantly

Signed-off-by: Edouard Lafargue <edouard@lafargue.name>
Acked-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-09-12 12:17:11 -03:00
Paul Mundt e7a963ef20 Merge branches 'sh/smp' and 'sh/stable-updates' 2009-09-08 16:27:31 +09:00
Randy Dunlap b6b85048c0 V4L/DVB (12502): gspca - sn9c20x: Fix gscpa sn9c20x build errors.
Reported-by: Toralf Forster <toralf.foerster@gmx.de>
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:54 -03:00
Shine Liu f4c5e80fab V4L/DVB (12495): em28xx: Don't call em28xx_ir_init when disable_ir is true
We should call em28xx_ir_init(dev) only when disable_ir is true.

Signed-off-by: Shine Liu <shinel@foxmail.com>
Reviewed-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:53 -03:00
Roel Kluin 7b808924d6 V4L/DVB (12457): zr364: wrong indexes
The order of indexes is reversed

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:53 -03:00
Udi Atar 31e0ad693f V4L/DVB (12451): Update KConfig File to enable SDIO and USB interfaces
Update KConfig file to enbale selection of SDIO and USB
interfaces, and add dependancy on relevant modules.

[mchehab@redhat.com: fix merge conflicts, remove default: m, add missing endmenu]

Signed-off-by: Udi Atar <udia@siano-ms.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:53 -03:00
Udi Atar ef2d12ce12 V4L/DVB (12450): Siano: Fixed SDIO compilation bugs
Fixed SDIO compilation bugs
Also fixed a memory overrun issue in buffer management.

Signed-off-by: Udi Atar <udia@siano-ms.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:53 -03:00
Mauro Carvalho Chehab f2e26ae7c8 V4L/DVB (12449): adds webcam for Micron device MT9M111 0x143A to em28xx
[mchehab@redhat.com: fix merge conflict and a few CodingStyle issues]
Signed-off-by: Steve Gotthardt <gotthardt@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:52 -03:00
Michael Krufky 3746b61780 V4L/DVB (12446): sms1xxx: restore GPIO functionality for all Hauppauge devices
Previous changesets broke Hauppauge devices and their GPIO configurations.

This changeset restores the LED & LNA functionality.

Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-31 02:24:52 -03:00
Magnus Damm 6d1386c6b8 v4l2: Runtime PM for SuperH Mobile CEU
This patch modifies the SuperH Mobile CEU driver to support
Runtime PM. Driver callbacks for Runtime PM are empty because
the device registers are always re-initialized after
pm_runtime_get_sync(). The Runtime PM functions replaces the
clock framework module stop bit handling in this driver.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2009-08-23 18:03:19 +09:00
Roel Kluin 08b39642b1 V4L/DVB (12441): siano: read buffer overflow
With mode DEVICE_MODE_RAW_TUNER a read occurs past the end of smscore_fw_lkup[].
Subsequently an attempt is made to load the firmware from the resulting
filename.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.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
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
Roel Kluin bb2b4542b6 V4L/DVB (12438): Read buffer overflow
parport[n] is checked before n < MAX_CAMS

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
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
Randy Dunlap 27059b3539 V4L/DVB (12437): dvb: siano uses/depends on INPUT
siano uses input_*() functions so it should depend on INPUT
to prevent build errors:

ERROR: "input_event" [drivers/media/dvb/siano/sms1xxx.ko] undefined!
ERROR: "input_register_device" [drivers/media/dvb/siano/sms1xxx.ko] undefined!
ERROR: "input_free_device" [drivers/media/dvb/siano/sms1xxx.ko] undefined!
ERROR: "input_unregister_device" [drivers/media/dvb/siano/sms1xxx.ko] undefined!
ERROR: "input_allocate_device" [drivers/media/dvb/siano/sms1xxx.ko] undefined!

Cc: Michael Krufky <mkrufky@linuxtv.org>
Cc: Uri Shkolnik <uris@siano-ms.com>
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-13 20:39:13 -03:00
Roel Kluin 77f2c2db11 V4L/DVB (12436): stk-webcam: read buffer overflow
It tested the value of stk_sizes[i].m before checking whether i was in range.

Cc: Hans Verkuil <hverkuil@xs4all.nl>
Cc: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-13 20:39:13 -03:00
Devin Heitmueller 01a5fd6ff3 V4L/DVB (12432): em28xx: fix regression in Empire DualTV digital tuning
Restore support for digital tuning caused by regression during introduction
of disable_i2c_gate parameter to zl10353 driver.

Thanks to user "Xwang" for reporting the problem and testing the fix

Cc: Xwang <xwang1976@email.it>
Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-13 20:39:13 -03:00
Hans Verkuil 9bedc7f7fe V4L/DVB (12429): v4l2-ioctl: fix G_STD and G_PARM default handlers
The v4l core supplies default handlers for G_STD and G_PARM. However, both
default handlers are buggy.

This patch fixes the following:

1) If no g_std is supplied and current_norm == 0, then this driver does not
   support TV video standards (e.g. a radio or webcam driver). Return
   -EINVAL. This ensures that there is no bogus VIDIOC_G_STD support for
   such drivers.

2) The default VIDIOC_G_PARM handler used current_norm instead of first
   checking if the driver supported g_std and calling that to get the norm.
   It also didn't check if current_norm was 0, since in that case the driver
   does not support TV standards (or no standard was set at all) and the
   default handler should return -EINVAL.

Note that I am very unhappy with these default handlers: I think they
basically behave like some very strange and unexpected side-effect.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-08-13 20:39:12 -03:00