kernel/kernel-generic.git
15 years agoV4L/DVB (9835): ivtv/ivtvfb: convert to v4l2_device/v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 22:38:23 +0000 (19:38 -0300)]
V4L/DVB (9835): ivtv/ivtvfb: convert to v4l2_device/v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9834): wm8775: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 16:03:22 +0000 (13:03 -0300)]
V4L/DVB (9834): wm8775: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9833): wm8739: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 16:02:26 +0000 (13:02 -0300)]
V4L/DVB (9833): wm8739: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9832): vp27smpx: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 16:01:28 +0000 (13:01 -0300)]
V4L/DVB (9832): vp27smpx: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9831): upd64083: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 16:00:30 +0000 (13:00 -0300)]
V4L/DVB (9831): upd64083: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9830): upd64031a: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:59:33 +0000 (12:59 -0300)]
V4L/DVB (9830): upd64031a: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9829): tuner: convert to v4l2_subdev.
Hans Verkuil [Mon, 24 Nov 2008 21:21:40 +0000 (18:21 -0300)]
V4L/DVB (9829): tuner: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9828): saa717x: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:57:44 +0000 (12:57 -0300)]
V4L/DVB (9828): saa717x: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9827): saa7127: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:56:38 +0000 (12:56 -0300)]
V4L/DVB (9827): saa7127: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9826): saa7115: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:55:19 +0000 (12:55 -0300)]
V4L/DVB (9826): saa7115: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9825): msp3400: convert to v4l2_subdev.
Hans Verkuil [Mon, 24 Nov 2008 21:16:46 +0000 (18:16 -0300)]
V4L/DVB (9825): msp3400: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9824): m52790: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:51:32 +0000 (12:51 -0300)]
V4L/DVB (9824): m52790: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9823): cx25840: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:50:06 +0000 (12:50 -0300)]
V4L/DVB (9823): cx25840: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9822): cs53l32a: convert to v4l2_subdev.
Hans Verkuil [Sat, 29 Nov 2008 15:45:59 +0000 (12:45 -0300)]
V4L/DVB (9822): cs53l32a: convert to v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9821): v4l2-common: add i2c helper functions
Hans Verkuil [Sun, 23 Nov 2008 15:19:45 +0000 (12:19 -0300)]
V4L/DVB (9821): v4l2-common: add i2c helper functions

Add helper functions to load i2c sub-devices, integrating them
into the v4l2-framework.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9820): v4l2: add v4l2_device and v4l2_subdev structs to the v4l2 framework.
Hans Verkuil [Sun, 30 Nov 2008 00:36:58 +0000 (21:36 -0300)]
V4L/DVB (9820): v4l2: add v4l2_device and v4l2_subdev structs to the v4l2 framework.

Start implementing a proper v4l2 framework as discussed during the
Linux Plumbers Conference 2008.

Introduces v4l2_device (for device instances) and v4l2_subdev (representing
sub-device instances).

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Reviewed-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Reviewed-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Reviewed-by: Andy Walls <awalls@radix.net>
Reviewed-by: David Brownell <david-b@pacbell.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9817): v4l: add new tvp514x I2C video decoder driver
Vaibhav Hiremath [Fri, 5 Dec 2008 13:19:36 +0000 (10:19 -0300)]
V4L/DVB (9817): v4l: add new tvp514x I2C video decoder driver

Signed-off-by: Brijesh Jadav <brijesh.j@ti.com>
Signed-off-by: Hardik Shah <hardik.shah@ti.com>
Signed-off-by: Manjunath Hadli <mrh@ti.com>
Signed-off-by: R Sivaraj <sivaraj@ti.com>
Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Karicheri Muralidharan <m-karicheri2@ti.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Reviewed-by: Hans Verkuil <hverkuil@xs4all.nl>
Reviewed-by: David Brownell <david-b@pacbell.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9816): v4l2-int-if: add three new ioctls for std handling and routing
Vaibhav Hiremath [Fri, 5 Dec 2008 13:13:40 +0000 (10:13 -0300)]
V4L/DVB (9816): v4l2-int-if: add three new ioctls for std handling and routing

These changes are needed for the new TVP514x driver.

Signed-off-by: Brijesh Jadav <brijesh.j@ti.com>
Signed-off-by: Hardik Shah <hardik.shah@ti.com>
Signed-off-by: Manjunath Hadli <mrh@ti.com>
Signed-off-by: R Sivaraj <sivaraj@ti.com>
Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Karicheri Muralidharan <m-karicheri2@ti.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9815): omap2: add OMAP2 camera driver.
Sakari Ailus [Mon, 1 Dec 2008 18:40:09 +0000 (15:40 -0300)]
V4L/DVB (9815): omap2: add OMAP2 camera driver.

Add a driver for the OMAP2 camera block. OMAP2 is used in e.g. Nokia
N800/N810 internet tablet.

This driver uses the V4L2 internal ioctl interface.

Signed-off-by: Sakari Ailus <sakari.ailus@nokia.com>
Signed-off-by: Trilok Soni <soni.trilok@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9812): [PATCH] short help for Technisat cards to select the right configuration
Patrick Boettcher [Wed, 10 Dec 2008 21:27:39 +0000 (18:27 -0300)]
V4L/DVB (9812): [PATCH] short help for Technisat cards to select the right configuration

This patch adds a short help for Technisat cards to help the user
selecting the right configuration for his card(s).

Signed-off-by: Uwe Bugla <uwe.bugla@gmx.de>
Signed-off-by: Patrick Boettcher <pb@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9811): Add support for the CX24113 DVB-S tuner driver
Patrick Boettcher [Sun, 23 Nov 2008 19:26:54 +0000 (16:26 -0300)]
V4L/DVB (9811): Add support for the CX24113 DVB-S tuner driver

This commit adds support for the CX24113 DVB-S tuner driver and thus support for the Technisat Skystar2 revision 2.8.
The driver was created with the help of Technisat. Thank you very much.

Signed-off-by: Patrick Boettcher <pb@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9810): uvcvideo: Add a device quirk to prune bogus controls.
Laurent Pinchart [Sat, 6 Dec 2008 20:43:40 +0000 (17:43 -0300)]
V4L/DVB (9810): uvcvideo: Add a device quirk to prune bogus controls.

Bogus controls currently include processing unit auto controls for which no
corresponding manual control is available. Such auto controls make little
sense if any, and are known to crash at least the SiGma Micro webcam.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9809): uvcvideo: Add nodrop module parameter to turn incomplete frame drop...
Laurent Pinchart [Sat, 6 Dec 2008 19:25:14 +0000 (16:25 -0300)]
V4L/DVB (9809): uvcvideo: Add nodrop module parameter to turn incomplete frame drop off.

The driver drops incomplete uncompressed video frames to avoid confusing
userspace with corrupt data. Add a nodrop module parameter to turn that
behaviour off and make all frames available to userspace.

Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9806): cx18: Enable raw VBI capture
Andy Walls [Fri, 12 Dec 2008 23:00:29 +0000 (20:00 -0300)]
V4L/DVB (9806): cx18: Enable raw VBI capture

A combined authorship patch from Hans Verkuil and Andy Walls.  Raw
VBI can now be captured but requires a video capture to be in progress as well.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9805): cx18: Port fix for raw/sliced VBI mixup from ivtv and cx25840
Andy Walls [Fri, 12 Dec 2008 19:24:04 +0000 (16:24 -0300)]
V4L/DVB (9805): cx18: Port fix for raw/sliced VBI mixup from ivtv and cx25840

This is a port of the fixes Hans Verkuil made for ivtv/cx25840:
The service_set field was used to determine whether raw or sliced VBI was
desired. This is incorrect since it is perfectly valid to select sliced VBI
with a service_set of 0.

Instead the driver should check on VIDIOC_S_FMT whether the type
field matches the raw or sliced VBI type.

Updated the cx18 driver accordingly, including an additional check in
cx18_start_v4l2_encode_stream() that didn't exist in ivtv.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9804): cx18: Avoid making firmware API calls with the queue lock held
Andy Walls [Fri, 12 Dec 2008 18:50:27 +0000 (15:50 -0300)]
V4L/DVB (9804): cx18: Avoid making firmware API calls with the queue lock held

cx18: Avoid making firmware API calls with the queue lock held.  The source
of MPEG strem corruption when not holding the queue lock was found to be that
the MPEG buffer could be retrieved by the user app before it was sync'ed for
the host cpu.  Incoming buffers are now sync'ed before being put on q_full and
releasing the queue lock.  We can thus avoid the sometimes lengthy call to
the firmware for CPU_DE_SET_MDL while holding the queue lock, so we can get
better performance.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9803): cx18: Increment version number due to siginificant buffering changes
Andy Walls [Tue, 9 Dec 2008 02:14:46 +0000 (23:14 -0300)]
V4L/DVB (9803): cx18: Increment version number due to siginificant buffering changes

cx18: Increment version number due to siginificant buffering changes.
Now version 1.0.4

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9802): cx18: Add module parameters for finer control over buffer allocations
Andy Walls [Mon, 8 Dec 2008 02:30:17 +0000 (23:30 -0300)]
V4L/DVB (9802): cx18: Add module parameters for finer control over buffer allocations

cx18: Add module parameters for finer control over buffer allocations.
User now has the option of setting smaller buffers to get lower
latency transfers from the encoder.  User can also now set the number
of buffers used for a stream explicitly.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9801): cx18: Allow more than 63 capture buffers in rotation per stream
Andy Walls [Tue, 9 Dec 2008 02:02:45 +0000 (23:02 -0300)]
V4L/DVB (9801): cx18: Allow more than 63 capture buffers in rotation per stream

cx18: Allow more than 63 capture buffers in rotation per stream.  Implement
q_busy to hold buffers the firmware has for use.  q_free holds truly unused
buffers in a pool.  New buffers are given to the firmware as soon as the
firmware returns one, if there are any to give to the firmware.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9800): cx18: Eliminate q_io from stream buffer handling
Andy Walls [Fri, 28 Nov 2008 03:04:21 +0000 (00:04 -0300)]
V4L/DVB (9800): cx18: Eliminate q_io from stream buffer handling

Eliminate q_io from stream buffer handling in anticipation of upcoming
changes in buffer handling.  q_io was a holdover from ivtv and it's function
in cx18 was trivial and not necessary.  We just push things back onto the
front of q_full now, instead of maintaining a 1 buffer q_io queue.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9799): em28xx: fix Kworld Hybrid 330 (A316) support
Mauro Carvalho Chehab [Tue, 9 Dec 2008 18:43:10 +0000 (15:43 -0300)]
V4L/DVB (9799): em28xx: fix Kworld Hybrid 330 (A316) support

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9798): saa7134: add analog and DVB-T support for Medion/Creatix CTX946
Hermann Pitton [Fri, 5 Dec 2008 22:49:34 +0000 (19:49 -0300)]
V4L/DVB (9798): saa7134: add analog and DVB-T support for Medion/Creatix CTX946

How to enable the mpeg encoder is not found yet.
The card comes up with gpio 0x0820000 for DVB-T.

Signed-off-by: Hermann Pitton <hermann-pitton@arcor.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9797): Fix stv0299 support in dw2102 USB DVB-S/S2 driver
Igor M. Liplianin [Thu, 4 Dec 2008 15:49:23 +0000 (12:49 -0300)]
V4L/DVB (9797): Fix stv0299 support in dw2102 USB DVB-S/S2 driver

register 0x00 contains 0xa1 for STV0299 and STV0299B
register 0x00 might contain 0x80 when returning from standby

Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Acked-by: Sergey Silkin <neovision@rambler.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9796): drivers/media/video/cx88/cx88-alsa.c: Adjust error-handling code
Julia Lawall [Tue, 2 Dec 2008 22:34:52 +0000 (19:34 -0300)]
V4L/DVB (9796): drivers/media/video/cx88/cx88-alsa.c: Adjust error-handling code

In the function cx88_audio_initdev, the value card has been created using
snd_card_new.  The other error handling code in this function frees the
value using snd_card_free.  I have thus changed the first error case to do
the same.  On the other hand, it may be that card is not sufficiently
initialized at this point to use snd_card_free, in which case something
else should be done to free the memory in the error case.

In the function snd_cx88_create the call kfree(chip) in one error case
looks suspicious, both because it is not done in the other error code, and
because chip points into the middle of the memory allocated by
snd_card_new, ie it is not itself associated with a separate kmalloc.
Therefore I have removed it.

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

// <smpl>
@r exists@
local idexpression x;
statement S,S1;
position p1,p2,p3;
expression E,E1;
type T,T1;
expression *ptr != NULL;
@@

(
 if ((x@p1 = snd_card_new(...)) == NULL) S
|
 x@p1 = snd_card_new(...);
)
 ... when != snd_card_free(...,(T)x,...)
     when != if (...) { <+... snd_card_free(...,(T)x,...) ...+> }
     when != true x == NULL || ...
     when != x = E
     when != E = (T)x
     when any
(
 if (x == NULL || ...) S1
|
 if@p2 (...) {
  ... when != snd_card_free(...,(T1)x,...)
      when != if (...) { <+... snd_card_free(...,(T1)x,...) ...+> }
      when != x = E1
      when != E1 = (T1)x
(
  return \(0\|<+...x...+>\|ptr\);
|
  return@p3 ...;
)
}
)

@ script:python @
p1 << r.p1;
p3 << r.p3;
@@

print "* file: %s snd_card_new: %s return: %s" % (p1[0].file,p1[0].line,p3[0].line)

// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9795): Add Compro VideoMate E650F (DVB-T part only).
Igor M. Liplianin [Sun, 23 Nov 2008 17:11:16 +0000 (14:11 -0300)]
V4L/DVB (9795): Add Compro VideoMate E650F (DVB-T part only).

Add Compro VideoMate E650F (DVB-T part only).
The card based on cx23885 PCI-Express chip, xc3028 tuner and ce6353 demodulator.

Cc: Steven Toth <stoth@linuxtv.org>
Signed-off-by: Igor M. Liplianin <liplianin@me.by>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9793): em28xx: Add specific entry for WinTV-HVR 850
Douglas Schilling Landgraf [Tue, 2 Dec 2008 00:01:04 +0000 (21:01 -0300)]
V4L/DVB (9793): em28xx: Add specific entry for WinTV-HVR 850

Added specific entry for WinTV-HVR 850

Signed-off-by: Douglas Schilling Landgraf <dougsland@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9791): pxa-camera: pixel format negotiation
Robert Jarzmik [Mon, 1 Dec 2008 12:45:35 +0000 (09:45 -0300)]
V4L/DVB (9791): pxa-camera: pixel format negotiation

Use the new format-negotiation infrastructure, support all four YUV422
packed and the planar formats.

The new translation structure enables to build the format
list with buswidth, depth, host format and camera format
checked, so that it's not done anymore on try_fmt nor
set_fmt.

Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9790): soc-camera: pixel format negotiation - core support
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:45:27 +0000 (09:45 -0300)]
V4L/DVB (9790): soc-camera: pixel format negotiation - core support

Allocate and fill a list of formats, supported by this specific
camera-host combination. Use it for format enumeration. Take care to stay
backwards-compatible.

Camera hosts rely on sensor formats available, as well as
host specific translations. We add a structure so that hosts
can define a translation table and use it for format check
and setup.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9789): soc-camera: add a per-camera device host private data pointer
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:45:24 +0000 (09:45 -0300)]
V4L/DVB (9789): soc-camera: add a per-camera device host private data pointer

This pointer will be used by pxa_camera.c to point to its pixel format
data.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9788): soc-camera: simplify naming
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:45:21 +0000 (09:45 -0300)]
V4L/DVB (9788): soc-camera: simplify naming

We anyway don't follow the s_fmt_vid_cap / g_fmt_vid_cap / try_fmt_vid_cap
naming, and soc-camera is so far only about video capture, let's simplify
operation names a bit further. set_fmt_cap / try_fmt_cap wasn't a very good
choice too.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9787): soc-camera: let camera host drivers decide upon pixel format
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:44:59 +0000 (09:44 -0300)]
V4L/DVB (9787): soc-camera: let camera host drivers decide upon pixel format

Pixel format requested by the user is not necessarily the same, as what
a sensor driver provides. There are situations, when a camera host driver
provides the required format, but requires a different format from the
sensor. Further, the list of formats, supported by sensors is pretty static
and can be pretty good described with a constant list of structures. Whereas
decisions, made by camera host drivers to support requested formats can be
quite complex, therefore it is better to let the host driver do the work.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9786): soc-camera: formatting fixes
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:44:56 +0000 (09:44 -0300)]
V4L/DVB (9786): soc-camera: formatting fixes

Minor formatting fixes

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9785): soc-camera: merge .try_bus_param() into .try_fmt_cap()
Guennadi Liakhovetski [Mon, 1 Dec 2008 12:44:53 +0000 (09:44 -0300)]
V4L/DVB (9785): soc-camera: merge .try_bus_param() into .try_fmt_cap()

.try_bus_param() method from struct soc_camera_host_ops is only called at one
location immediately before .try_fmt_cap(), there is no value in keeping these
two methods separate, merge them.

Signed-off-by: Guennadi Liakhovetski <lg@denx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9784): Register name fix for ov772x driver
Kuninori Morimoto [Mon, 1 Dec 2008 12:44:51 +0000 (09:44 -0300)]
V4L/DVB (9784): Register name fix for ov772x driver

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9783): Change power on/off sequence on ov772x
Kuninori Morimoto [Mon, 1 Dec 2008 12:44:48 +0000 (09:44 -0300)]
V4L/DVB (9783): Change power on/off sequence on ov772x

Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9778): cx18: cx18_writel_expect() should not declare success on a PCI read...
Andy Walls [Sun, 30 Nov 2008 13:01:21 +0000 (10:01 -0300)]
V4L/DVB (9778): cx18: cx18_writel_expect() should not declare success on a PCI read error

cx18: cx18_writel_expect() should not declare success on a PCI read error.
This removes the potential for cx18_write*_expect() calls to not
accomplish a PCI write successfully as expected.  The CX18-AV core uses the
*expect() calls often and this may be the source of intermittent audio
problems and standands switching problems.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9776): cx18: Change to per CX23418 device work queues for deferrable work...
Andy Walls [Wed, 26 Nov 2008 00:43:05 +0000 (21:43 -0300)]
V4L/DVB (9776): cx18: Change to per CX23418 device work queues for deferrable work handling

cx18: Change to per CX23418 device work queues for deferrable work handling.
Needed to support 2.6.22 and earlier kernels that can't selectively cancel
work orders.  Also will provide slightly better performance on SMP systems.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9775): tda8290: fix FM radio
Mauro Carvalho Chehab [Mon, 8 Dec 2008 13:36:57 +0000 (10:36 -0300)]
V4L/DVB (9775): tda8290: fix FM radio

tda8290 were using some random video standard for FM. This results on random
errors. Instead, program tda8290 in expert mode, using a configuration near the
one specified on NXP datasheet for tda8295 (available on their site).

Also, properly display that the device is on radio mode.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9774): tda827x: fix returned frequency
Mauro Carvalho Chehab [Mon, 8 Dec 2008 03:49:33 +0000 (00:49 -0300)]
V4L/DVB (9774): tda827x: fix returned frequency

Probably due to a removed code, tda827x were doing some wrong calculus at the
returned frequency. I suspect that the original idea were to return the
programmed divisor converted into frequency again.

However, the current code is sometimes multiplying the programmed frequency by
62500, and, on other cases, like radio, it dividing it by 1000.

Instead of doing such math, let's just store the frequency value as requested by
the caller module.

Cc: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9773): tda827x: fix printk message when in FM mode
Mauro Carvalho Chehab [Mon, 8 Dec 2008 02:01:57 +0000 (23:01 -0300)]
V4L/DVB (9773): tda827x: fix printk message when in FM mode

Cc: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9772): saa7134: Add support for Kworld Plus TV Analog Lite PCI
Mauro Carvalho Chehab [Sun, 7 Dec 2008 16:19:29 +0000 (13:19 -0300)]
V4L/DVB (9772): saa7134: Add support for Kworld Plus TV Analog Lite PCI

Thanks to Sistema Fenix (http://www.sistemafenix.com.br/) for sponsoring
this
development.

Signed-off-by: Gilberto <gilberto@sistemafenix.com.br>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9771): tuner-xc2028: fix a small warning
Mauro Carvalho Chehab [Fri, 5 Dec 2008 13:49:53 +0000 (10:49 -0300)]
V4L/DVB (9771): tuner-xc2028: fix a small warning

/home/mauro/v4l-dvb/v4l/tuner-xc2028.c: In function 'xc2028_sleep':
/home/mauro/v4l-dvb/v4l/tuner-xc2028.c:1111: warning: 'return' with no value, in function returning non-void

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9770): em28xx: turn off tuner when not used
Mauro Carvalho Chehab [Fri, 5 Dec 2008 13:39:12 +0000 (10:39 -0300)]
V4L/DVB (9770): em28xx: turn off tuner when not used

em28xx devices generally get hot when xc3028 tuner is powered on. This
patch solves this by turning power off when the device is not used, at the
expense of having a higher load time, when calling a TV application.

Since firmware load happens on 1 or 2 seconds on most devices, this is not a pain.

Also, it helps to save the planet by saving some power :)

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9769): tuner-xc2028: powers device of when not used
Mauro Carvalho Chehab [Fri, 5 Dec 2008 13:31:16 +0000 (10:31 -0300)]
V4L/DVB (9769): tuner-xc2028: powers device of when not used

Since the firmware load is now fast on most boards, better to keep the tuner
off by default. A modprobe parameter were added to keep the old behavior,
to be used by old devices.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9756): em28xx: Improve register log format
Mauro Carvalho Chehab [Wed, 26 Nov 2008 12:58:48 +0000 (09:58 -0300)]
V4L/DVB (9756): em28xx: Improve register log format

Change log format to look more like URB transactions. In fact, setup and
IN/OUT transactions are merged. This helps to debug the driver.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9737): sms1xxx: enable LNA control on Hauppauge WinTV MiniCard
Michael Krufky [Sat, 22 Nov 2008 17:33:00 +0000 (14:33 -0300)]
V4L/DVB (9737): sms1xxx: enable LNA control on Hauppauge WinTV MiniCard

Power the LNA while the frontend is in use.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9730): cx18: Quiet a sometimes common warning that often has benign consequences
Andy Walls [Sun, 23 Nov 2008 19:27:57 +0000 (16:27 -0300)]
V4L/DVB (9730): cx18: Quiet a sometimes common warning that often has benign consequences

cx18: Quiet a sometimes common warning that often has benign consequences.
No one probably cares that the firmware took forever to ack our command, as
they always seem to succeed whether or not the firmware acks it in a reasonable
amount of time.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9729): cx18: Update version due to significant irq handling changes
Andy Walls [Sat, 22 Nov 2008 04:40:11 +0000 (01:40 -0300)]
V4L/DVB (9729): cx18: Update version due to significant irq handling changes

Update the version number due to significant changes in the way the
mailboxes and interrupts are handled.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9728): cx18: Copyright attribution update for files modified by awalls
Andy Walls [Sat, 22 Nov 2008 04:37:34 +0000 (01:37 -0300)]
V4L/DVB (9728): cx18: Copyright attribution update for files modified by awalls

Add copyright attribution for files modified by awalls in 2008

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9727): cx18: Adjust outgoing mailbox timeouts and remove statistics logging
Andy Walls [Sat, 22 Nov 2008 04:23:22 +0000 (01:23 -0300)]
V4L/DVB (9727): cx18: Adjust outgoing mailbox timeouts and remove statistics logging

cx18: Adjust outgoing mailbox timeouts and remove statistics logging.
This saves some wasted storage in struct cx18 for each card.  Cutting
the outgoing mailbox timeouts in half from the previous value appears to
be safe with MythTV.  Got rid of interrupted case code path after
a wait uninterruptable returns.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9726): cx18: Restore buffers that have fallen out of the transfer rotation
Andy Walls [Wed, 19 Nov 2008 04:24:33 +0000 (01:24 -0300)]
V4L/DVB (9726): cx18: Restore buffers that have fallen out of the transfer rotation

Restore buffers that have fallen out of the transfer rotation, and check
for coherent mailbox data when processing a stale mailbox.

Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
15 years agoV4L/DVB (9725): cx18: Remove unnecessary MMIO accesses in time critical irq handling...
Andy Walls [Tue, 18 Nov 2008 01:48:46 +0000 (22:48 -0300)]
V4L/DVB (9725): cx18: Remove unnecessary MMIO accesses in time critical irq handling path

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Also, documents the register names that are known.

This patch were generated by this small perl script:

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

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

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

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

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

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

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

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

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

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

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

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

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

Also, it does some whitespace cleanups.

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

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

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

So, almost 100 lines of hacking magic were removed.

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

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

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

Signed-off-by: Devin Heitmueller <devin.heitmueller@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>