• Home
  • History
  • Annotate
  • only in /drivers/media/video/usbvision/
History log of /drivers/media/video/usbvision/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
12cbfd0a3c52a52c2948c91b9e62e73c468d1572 23-Nov-2011 Mauro Carvalho Chehab <mchehab@redhat.com> Merge tag 'v3.2-rc2' into staging/for_v3.3

* tag 'v3.2-rc2': (3068 commits)
Linux 3.2-rc2
hfs: add sanity check for file name length
fsl-rio: fix compile error
blackfin: Fixup export.h includes
Blackfin: add serial TX IRQ in individual platform resource
virtio-pci: fix use after free
ACPI / cpuidle: Remove acpi_idle_suspend (to fix suspend regression)
drm/radeon/kms/combios: fix dynamic allocation of PM clock modes
[CPUFREQ] db8500: fix build error due to undeclared i variable
bma023: Add SFI translation for this device
vrtc: change its year offset from 1960 to 1972
ce4100: fix a build error
arm/imx: fix imx6q mmc error when mounting rootfs
arm/imx: fix AUTO_ZRELADDR selection
arm/imx: fix the references to ARCH_MX3
ARM: mx51/53: set pwm clock parent to ipg_perclk
btrfs: rename the option to nospace_cache
drm/radeon/kms/pm: switch to dynamically allocating clock mode array
drm/radeon/kms: optimize r600_pm_profile_init
drm/radeon/kms/pm: add a proper pm profile init function for fusion
...

Conflicts:
drivers/media/radio/Kconfig
819cd82b0a994d9d83dc1d1ced1088e71d702d4c 07-Nov-2011 Jean Delvare <khali@linux-fr.org> [media] usbvision: Drop broken 10-bit I2C address support

The support for 10-bit I2C addresses in usbvision seems plain broken
to me. I had already noticed that back in February 2007 [1]. The code
was not fixed since then, so I take it that it's not actually needed.
And as a matter of fact I don't know of any 10-bit addressed I2C
tuner, encode, decoder or the like.

So let's simply get rid of the broken and useless code.

I'm also adding I2C_FUNC_I2C, as the driver and hardware support plain
I2C messaging.

[1] http://marc.info/?l=linux-i2c&m=117499415208244&w=2

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
32aaeffbd4a7457bf2f7448b33b5946ff2a960eb 07-Nov-2011 Linus Torvalds <torvalds@linux-foundation.org> Merge branch 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux

* 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux: (230 commits)
Revert "tracing: Include module.h in define_trace.h"
irq: don't put module.h into irq.h for tracking irqgen modules.
bluetooth: macroize two small inlines to avoid module.h
ip_vs.h: fix implicit use of module_get/module_put from module.h
nf_conntrack.h: fix up fallout from implicit moduleparam.h presence
include: replace linux/module.h with "struct module" wherever possible
include: convert various register fcns to macros to avoid include chaining
crypto.h: remove unused crypto_tfm_alg_modname() inline
uwb.h: fix implicit use of asm/page.h for PAGE_SIZE
pm_runtime.h: explicitly requires notifier.h
linux/dmaengine.h: fix implicit use of bitmap.h and asm/page.h
miscdevice.h: fix up implicit use of lists and types
stop_machine.h: fix implicit use of smp.h for smp_processor_id
of: fix implicit use of errno.h in include/linux/of.h
of_platform.h: delete needless include <linux/module.h>
acpi: remove module.h include from platform/aclinux.h
miscdevice.h: delete unnecessary inclusion of module.h
device_cgroup.h: delete needless include <linux/module.h>
net: sch_generic remove redundant use of <linux/module.h>
net: inet_timewait_sock doesnt need <linux/module.h>
...

Fix up trivial conflicts (other header files, and removal of the ab3550 mfd driver) in
- drivers/media/dvb/frontends/dibx000_common.c
- drivers/media/video/{mt9m111.c,ov6650.c}
- drivers/mfd/ab3550-core.c
- include/linux/dmaengine.h
7a707b89202f905bd9f9fbde326933c59a81214c 03-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com> drivers/media: Add module.h to all files using it implicitly

A pending cleanup will mean that module.h won't be implicitly
everywhere anymore. Make sure the modular drivers in clocksource
are actually calling out for <module.h> explicitly in advance.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
sbvision-cards.c
3f5c14d3d3d7a3f508f2fffa62731f13f8efdfba 15-Aug-2011 Arnaud Lacombe <lacombar@gmail.com> [media] drivers/media: do not use EXTRA_CFLAGS

Usage of these flags has been deprecated for nearly 4 years by:

commit f77bf01425b11947eeb3b5b54685212c302741b8
Author: Sam Ravnborg <sam@neptun.(none)>
Date: Mon Oct 15 22:25:06 2007 +0200

kbuild: introduce ccflags-y, asflags-y and ldflags-y

Moreover, these flags (at least EXTRA_CFLAGS) have been documented for command
line use. By default, gmake(1) do not override command line setting, so this is
likely to result in build failure or unexpected behavior.

Replace their usage by Kbuild's `{as,cc,ld}flags-y'.

Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: linux-media@vger.kernel.org
Signed-off-by: Arnaud Lacombe <lacombar@gmail.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
akefile
1990d50b58bef127a647005fdcada6d07081d3ef 24-Jun-2011 Mauro Carvalho Chehab <mchehab@redhat.com> [media] Stop using linux/version.h on most video drivers

All the modified drivers didn't have any version increment since
Jan, 1 2011. Several of them didn't have any version increment
for a long time, even having new features and important bug fixes
happening.

As we're now filling the QUERYCAP version with the current Kernel
Release, we don't need to maintain a per-driver version control
anymore. So, let's just use the default.

In order to preserve the Kernel module version history, a
KERNEL_VERSION() macro were added to all modified drivers, and
the extraver number were incremented.

I opted to preserve the per-driver version control to a few
pwc, pvrusb2, s2255, s5p-fimc and sh_vou.

A few drivers are still using the legacy way to handle ioctl's.
So, we can't do such change on them, otherwise, they'll break.
Those are: uvc, et61x251 and sn9c102.

The rationale is that the per-driver version control seems to be
actively maintained on those.

Yet, I think that the better for them would be to just use the
default version numbering, instead of doing that by themselves.

While here, removed a few uneeded include linux/version.h

Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
df462b3dbeeaae7141f1b63cbfcc1e1bae6a85fc 24-May-2011 Linus Torvalds <torvalds@linux-foundation.org> Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6

* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (247 commits)
[media] gspca - sunplus: Fix some warnings and simplify code
[media] gspca: Fix some warnings tied to 'no debug'
[media] gspca: Unset debug by default
[media] gspca - cpia1: Remove a bad conditional compilation instruction
[media] gspca - main: Remove USB traces
[media] gspca - main: Version change to 2.13
[media] gspca - stk014 / t613: Accept the index 0 in querymenu
[media] gspca - kinect: Remove __devinitdata
[media] gspca - cpia1: Fix some warnings
[media] video/Kconfig: Fix mis-classified devices
[media] support for medion dvb stick 1660:1921
[media] tm6000: fix uninitialized field, change prink to dprintk
[media] cx231xx: Add support for Iconbit U100
[media] saa7134 add new TV cards
[media] Use a more consistent value for RC repeat period
[media] cx18: Move spinlock and vb_type initialisation into stream_init
[media] tm6000: remove tm6010 sif audio start and stop
[media] tm6000: remove unused exports
[media] tm6000: add pts logging
[media] tm6000: change from ioctl to unlocked_ioctl
...
59983439c09f0d319cd288d27c0f70cf8764e09a 27-Apr-2011 Ondrej Zary <linux@rainbow-software.org> [media] usbvision: remove broken testpattern

Enabling force_testpattern module parameter in usbvision causes kernel panic.
Things like that does not belong to the kernel anyway so the fix is easy.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
240d57bb8238d6998644c7f696c27076956ff653 27-Apr-2011 Ondrej Zary <linux@rainbow-software.org> [media] usbvision: add Nogatech USB MicroCam

Add Nogatech USB MicroCam PAL (NV3001P) and NTSC (NV3000N) support to
usbvision driver.
PAL version is tested, NTSC untested.
Data captured using usbsnoop, init_values are listed in the INF file along
with image dimensions, offsets and frame rates.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-cards.c
sbvision-cards.h
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
85ee7a1d39d75d23d21f3871f6dc9b87d572747a 24-Apr-2011 Joe Perches <joe@perches.com> treewide: cleanup continuations and remove logging message whitespace

Using C line continuation inside format strings is error prone.
Clean up the unintended whitespace introduced by misuse of \.
Neaten correctly used line continations as well for consistency.

drivers/scsi/arcmsr/arcmsr_hba.c has these errors as well,
but arcmsr needs a lot more work and the driver should likely be
moved to staging instead.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
sbvision-video.c
6d6a48e51fd3bcb40c5b88d0f9690ba960eedfd2 29-Dec-2010 Hans Verkuil <hverkuil@xs4all.nl> [media] usbvision: coding style

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-cards.c
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
52cb0bf275debe4ec8950157f11b9d9f14447a88 20-Dec-2010 Hans Verkuil <hverkuil@xs4all.nl> [media] usbvision: convert // to /* */

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
5490a7cbe65d63c6ec45f1013287af1e390c95d7 20-Dec-2010 Hans Verkuil <hverkuil@xs4all.nl> [media] usbvision: get rid of camelCase

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-cards.c
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
c627b9d1f580f26fe99a8045d37a57f91e9aef66 18-Dec-2010 Hans Verkuil <hverkuil@xs4all.nl> [media] usbvision: convert to unlocked_ioctl

Convert driver to use core-assisted locking.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-video.c
sbvision.h
08af245de0cf6ab5f4ed008ee2bb99273774fce0 24-Dec-2010 Hans Verkuil <hverkuil@xs4all.nl> [media] V4L: remove V4L1 compatibility mode

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
53f517a1f61ce69bf67898891d5b14ffaada0003 02-Dec-2010 Linus Torvalds <torvalds@linux-foundation.org> Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6

* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6:
[media] v4l: Remove module_name argument to the v4l2_i2c_new_subdev* functions
[media] v4l: Remove hardcoded module names passed to v4l2_i2c_new_subdev* (2)
9a1f8b34aa539000da17a06235e4bec254d0bfb5 24-Sep-2010 Laurent Pinchart <laurent.pinchart@ideasonboard.com> [media] v4l: Remove module_name argument to the v4l2_i2c_new_subdev* functions

The argument isn't used anymore by the functions, remove it.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
451a3c24b0135bce54542009b5fde43846c7cf67 17-Nov-2010 Arnd Bergmann <arnd@arndb.de> BKL: remove extraneous #include <smp_lock.h>

The big kernel lock has been removed from all these files at some point,
leaving only the #include.

Remove this too as a cleanup.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-video.c
1532a07042289d420f040f3bd4370cc106860003 24-Sep-2010 Laurent Pinchart <laurent.pinchart@ideasonboard.com> [media] v4l: Remove hardcoded module names passed to v4l2_i2c_new_subdev*

With the v4l2_i2c_new_subdev* functions now supporting loading modules
based on modaliases, replace the hardcoded module name passed to those
functions by NULL.

All corresponding I2C modules have been checked, and all of them include
a module aliases table with names corresponding to what the drivers
modified here use.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
8403472f19fea7e7cec7899e998f38b899e59604 17-Sep-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: usbvision: remove BKL from usbvision

Removed the BKL from usbvision.

There was an initialization bug as well where the i2c bus was registered twice.

Although when the BKL was present no oops was generated, I did run into
other i2c problems. Now that I protect against duplicate i2c registration
that bug is now gone as well.

But trying to disconnect the USB cable while someone is still using the device
still leads to a crash.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
sbvision-video.c
sbvision.h
4202066c6995200b2755a4501ea90f5d4e163e41 27-May-2010 Julia Lawall <julia@diku.dk> V4L/DVB: drivers/media: Eliminate a NULL pointer dereference

In each case, the print involves dereferencing a value that is NULL or is
near NULL.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@r exists@
expression E,E1;
identifier f;
statement S1,S2,S3;
@@

if ((E == NULL && ...) || ...)
{
... when != if (...) S1 else S2
when != E = E1
* E->f
... when any
return ...;
}
else S3
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
7a9b149212f3716c598afe973b6261fd58453b7a 21-May-2010 Linus Torvalds <torvalds@linux-foundation.org> Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (229 commits)
USB: remove unused usb_buffer_alloc and usb_buffer_free macros
usb: musb: update gfp/slab.h includes
USB: ftdi_sio: fix legacy SIO-device header
USB: kl5usb105: reimplement using generic framework
USB: kl5usb105: minor clean ups
USB: kl5usb105: fix memory leak
USB: io_ti: use kfifo to implement write buffering
USB: io_ti: remove unsused private counter
USB: ti_usb: use kfifo to implement write buffering
USB: ir-usb: fix incorrect write-buffer length
USB: aircable: fix incorrect write-buffer length
USB: safe_serial: straighten out read processing
USB: safe_serial: reimplement read using generic framework
USB: safe_serial: reimplement write using generic framework
usb-storage: always print quirks
USB: usb-storage: trivial debug improvements
USB: oti6858: use port write fifo
USB: oti6858: use kfifo to implement write buffering
USB: cypress_m8: use kfifo to implement write buffering
USB: cypress_m8: remove unused drain define
...

Fix up conflicts (due to usb_buffer_alloc/free renaming) in
drivers/input/tablet/acecad.c
drivers/input/tablet/kbtab.c
drivers/input/tablet/wacom_sys.c
drivers/media/video/gspca/gspca.c
sound/usb/usbaudio.c
997ea58eb92f9970b8af7aae48800d0ef43b9423 12-Apr-2010 Daniel Mack <daniel@caiaq.de> USB: rename usb_buffer_alloc() and usb_buffer_free() users

For more clearance what the functions actually do,

usb_buffer_alloc() is renamed to usb_alloc_coherent()
usb_buffer_free() is renamed to usb_free_coherent()

They should only be used in code which really needs DMA coherency.

All call sites have been changed accordingly, except for staging
drivers.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Alan Stern <stern@rowland.harvard.edu>
Cc: Pedro Ribeiro <pedrib@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
sbvision-core.c
4d6c871ac338a8d804a1139dade2a463614d3e34 02-May-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: usbvision: add delay before detecting the saa711x

The detection of the saa711x often failed. Adding a small delay before
attempting to detect it fixed this.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
aeb506aaaa08bc1910650666463843a73c34b139 02-May-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: usbvision: don't use usb_set_intfdata, let v4l2_device_register handle this

v4l2_device_register already sets intfdata, no need to do this again.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
sbvision.h
fa0290eaee03c3205cb6d344db25580fb3e5e53e 06-Apr-2010 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB: usbvision: remove non-working vbi device

The usbvision driver created vbi device nodes but the actual implementation
was just stubs and only returned errors to userspace.

In addition it used video_usercopy() and we want to remove that eventually.

So remove all the vbi code except for the vbi flag in the card definition
should someone ever be mad enough to work on a proper implementation for this
driver.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
sbvision.h
5a0e3ad6af8660be21ca98a971cd00f331318c05 24-Mar-2010 Tejun Heo <tj@kernel.org> include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h

percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files. percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed. Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability. As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
only the necessary includes are there. ie. if only gfp is used,
gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
blocks and try to put the new include such that its order conforms
to its surrounding. It's put in the include block which contains
core kernel includes, in the same order that the rest are ordered -
alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
because the file doesn't have fitting include block), it prints out
an error message indicating which .h file needs to be added to the
file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
over 4000 files, deleting around 700 includes and adding ~480 gfp.h
and ~3000 slab.h inclusions. The script emitted errors for ~400
files.

2. Each error was manually checked. Some didn't need the inclusion,
some needed manual addition while adding it to implementation .h or
embedding .c file was more appropriate for others. This step added
inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
e.g. lib/decompress_*.c used malloc/free() wrappers around slab
APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
editing them as sprinkling gfp.h and slab.h inclusions around .h
files could easily lead to inclusion dependency hell. Most gfp.h
inclusion directives were ignored as stuff from gfp.h was usually
wildly available and often used in preprocessor macros. Each
slab.h inclusion directive was examined and added manually as
necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
distributed build env didn't work with gcov compiles) and a few
more options had to be turned off depending on archs to make things
build (like ipr on powerpc/64 which failed due to missing writeq).

* x86 and x86_64 UP and SMP allmodconfig and a custom test config.
* powerpc and powerpc64 SMP allmodconfig
* sparc and sparc64 SMP allmodconfig
* ia64 SMP allmodconfig
* s390 SMP allmodconfig
* alpha SMP allmodconfig
* um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
sbvision-core.c
sbvision-i2c.c
3557aa4f7ddaec2903532595d2caccac32a5bbeb 28-Dec-2009 Julia Lawall <julia@diku.dk> V4L/DVB (13954): Correct NULL test

Test the just-allocated value for NULL rather than some other value.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r@
identifier f;
@@

f(...) { <+... return NULL; ...+> }

@@
expression *x;
expression y;
identifier r.f;
statement S;
@@

x = f(...);
(
if ((x) == NULL) S
|
if (
- y
+ x
== NULL)
S
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
46b21094cee16bc7e531d7d6cd66fb5ea05065d4 10-Dec-2009 Laurent Pinchart <laurent.pinchart@ideasonboard.com> V4L/DVB (13556): v4l: Remove unneeded video_device::minor assignments

Now that the video_device registration is tested using
video_is_registered(), drivers don't need to initialize the
video_device::minor field to -1 anymore.

Remove those unneeded assignments.

[mchehab.redhat.com: removed tm6000 changes as tm6000 is not ready yet for submission even on staging]

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
f0813b4c9f7ffbeaddcba1c08a1812f7ff30e1b7 27-Nov-2009 Laurent Pinchart <laurent.pinchart@ideasonboard.com> V4L/DVB (13553): v4l: Use the video_is_registered function in device drivers

Fix all device drivers to use the video_is_registered function instead
of checking video_device::minor.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
0fda5d4420fe1d6a19189386b6bc6532c97a7e0e 27-Nov-2009 Laurent Pinchart <laurent.pinchart@ideasonboard.com> V4L/DVB (13551): v4l: Remove video_device::num usage from device drivers

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
38c7c036036c6260606a2a833aaad3794ca22499 27-Nov-2009 Laurent Pinchart <laurent.pinchart@ideasonboard.com> V4L/DVB (13550): v4l: Use the new video_device_node_name function

Fix all device drivers to use the new video_device_node_name function.

This also strips kernel log messages from the "/dev/" prefix, has the device
node location is a userspace policy decision unknown to the kernel.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
f14a2972e40dbfbe7077ec7ab21cc2729f7e7d6d 23-Oct-2009 Roel Kluin <roel.kluin@gmail.com> V4L/DVB (13241): Cleanup redundant tests on unsigned

The variables are unsigned so the test `>= 0' is always true,
the `< 0' test always fails. In these cases the other part of
the test catches wrapped values.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
2bcd57ab61e7cabed626226a3771617981c11ce1 24-Sep-2009 Alexey Dobriyan <adobriyan@gmail.com> headers: utsname.h redux

* remove asm/atomic.h inclusion from linux/utsname.h --
not needed after kref conversion
* remove linux/utsname.h inclusion from files which do not need it

NOTE: it looks like fs/binfmt_elf.c do not need utsname.h, however
due to some personality stuff it _is_ needed -- cowardly leave ELF-related
headers and files alone.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
53dacb15705901e14b03dcba27e40364fedd9d09 10-Aug-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (12540): v4l: simplify v4l2_i2c_new_subdev and friends

Rewrite v4l2_i2c_new_subdev as a simplified version of v4l2_i2c_new_subdev_cfg
and remove v4l2_i2c_new_probed_subdev and v4l2_i2c_new_probed_subdev_addr.

This simplifies this API substantially.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
405f55712dfe464b3240d7816cc4fe4174831be2 11-Jul-2009 Alexey Dobriyan <adobriyan@gmail.com> headers: smp_lock.h redux

* Remove smp_lock.h from files which don't need it (including some headers!)
* Add smp_lock.h to files which do need it
* Make smp_lock.h include conditional in hardirq.h
It's needed only for one kernel_locked() usage which is under CONFIG_PREEMPT

This will make hardirq.h inclusion cheaper for every PREEMPT=n config
(which includes allmodconfig/allyesconfig, BTW)

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-video.c
e36bc31f823d6089bedc935fea82b6d36793412a 04-Jun-2009 Jean Delvare <khali@linux-fr.org> V4L/DVB (11992): Add missing __devexit_p()

Add missing __devexit_p() to several drivers. Also add a few missing
__init, __devinit and __exit markers. These errors could result in
build failures depending on the kernel configuration.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
5e2c217eee18a4627a32c49f57f47dbac67dcf23 11-Jun-2009 Figo.zhang <figo1802@gmail.com> V4L/DVB (11958): usbvision-core.c: vfree does its own NULL check

vfree() does it's own NULL checking,so no need for check before
calling it.

Signed-off-by: Figo.zhang <figo1802@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
223ffe5f8270ba9d069f1cbff9acec095a6f58b1 02-May-2009 Roel Kluin <roel.kluin@gmail.com> V4L/DVB: cleanup redundant tests on unsigned

Remove redundant tests on unsigned.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
f2caedd919bfef6abe9ad99cf3e210615f6a692d 02-Apr-2009 Huang Weiyi <weiyi.huang@gmail.com> V4L/DVB: usbvision: remove unused #include <version.h>

Remove unused #include <version.h> in
drivers/media/video/usbvision/usbvision-i2c.c.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
5325b4272a53b43f55b82cc369c310c2fcacdca1 02-Apr-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11380): v4l2-subdev: change s_routing prototype

It is no longer needed to use a struct pointer as argument, since v4l2_subdev
doesn't require that ioctl-like approach anymore. Instead just pass the input,
output and config (new!) arguments directly.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
3ff4ad815c5824ab35375d72ea8fe14fb3230daa 01-Apr-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11377): v4l: increase version numbers of drivers converted to v4l2_subdev.

With all the v4l2_subdev changes that were made to these drivers it is a
good idea to increase the version number of each driver.

It's just the patch level that is increased, except for the zoran and saa7146
drivers where the minor number was increased due to the more substantial
changes that were made to those two drivers.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
e6574f2fbecdb8af807169d345c10131ae060a88 01-Apr-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11373): v4l2-common: add explicit v4l2_device pointer as first arg to new_(probed)_subdev

The functions v4l2_i2c_new_subdev and v4l2_i2c_new_probed_subdev relied on
i2c_get_adapdata to return the v4l2_device. However, this is not always
possible on embedded platforms. So modify the API to pass the v4l2_device
pointer explicitly.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
f41737ece472cd803ffb24ac9f5d6fdd1d871341 01-Apr-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11370): v4l2-subdev: move s_std from tuner to core.

s_std didn't belong in the tuner ops. Stricly speaking it should be part of
the video ops, but it is used by audio and tuner devices as well, so it is
more efficient to make it part of the core ops.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
a878440d994e11bc3e4eb81d378b32fa32e9d80c 01-Apr-2009 Janne Grunau <j@jannau.net> V4L/DVB (11354): usbvision: use usb_interface.dev for v4l2_device_register

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
975f5766be048fb65eae6dbf423db129cd641124 29-Mar-2009 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (11271): usbvision: Remove buffer type checks from enum_fmt_vid_cap, XXXbuf

The v4l2-ioctl core only allows buffer types for which the corresponding
->vidioc_try_fmt_xxx() methods are defined to be used with
vidioc_(q|dq|query)buf() and vidioc_reqbufs().

Since this driver only defines ->vidioc_try_fmt_vid_cap() the checks can be
removed from vidioc_reqbufs(), vidioc_qbuf(), and vidioc_dqbuf().

The ->vidioc_(s|g|try|enum)_fmt_vid_cap() methods are only called on
VIDEO_CAPTURE buffers. Thus, there is no need to check or set the buffer's
'type' field since it must already be set to VIDEO_CAPTURE. So setting the
buffer type in vidioc_enum_fmt_vid_cap() can be removed.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
f876897015e15e879ad531f78260086a7fdee813 23-Mar-2009 Devin Heitmueller <dheitmueller@linuxtv.org> V4L/DVB (11140): usbvision: fix oops on ARM platform when allocating transfer buffers

Add missing URB_NO_TRANSFER_DMA_MAP flag, since the use of consistent memory
is not permitted for DMA on the ARM platform.

Thanks to Paul Thomas <pthomas8589@gmail.com> for providing sample ARM hardware
that was experiencing the oops (tested on the at91rm9200 based LinuxStamp).

Thanks to David Brownell <david-b@pacbell.net> for providing insight into the
ARM memory architecture.

Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
15965f063d6d42bd451415923c4cccbdb4a61bdd 14-Mar-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11051): v4l-dvb: replace remaining references to the old mailinglist.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision.h
f1ba28c3a6e472742cbd73b05b807684e5d56b5a 14-Mar-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (11045): v4l2: call v4l2_device_disconnect in USB drivers.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
38367255185408748c2d46641e06c83570af161c 04-Mar-2009 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (10818): usbvision: Don't need to zero ioctl parameter fields

The v4l2 core code in v4l2_ioctl will zero out the structure the driver is
supposed to fill in for read-only ioctls. For read/write ioctls, all the
fields which aren't supplied from userspace will be zeroed out.

Zeroing code is removed from g_audio, queryctrl, and enum_fmt_vid_cap.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
9cfb6a3f1b16e82fab97831265858aa2d1983883 04-Mar-2009 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (10794): v4l2: Move code to zero querybuf output struct to v4l2_ioctl

For VIDIOC_QUERYBUF only the first two fields, size and type, are used as
input. The rest can be filled in by the driver as output. Most drivers do
not actually use all the field and unused ones should be zeroed out. Some
drivers have code to do this and some drivers should but don't. So put
some zero out code in v4l2_ioctl so that all drivers using that system get
it.

The drivers that have zeroing code get that code removed.

Some drivers checked that the type field was valid, but v4l2_ioctl already
does this so those checks can be removed as well.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
770060385a1694a8d909e7872c4ce0703da2b069 27-Feb-2009 Mauro Carvalho Chehab <mchehab@redhat.com> V4L/DVB (10738): Get rid of video_decoder.h header were uneeded

Now, just a few modules are still dependent of this legacy header:

$ grep -l DECODER_ `find linux/drivers/media/ -name '*.[ch]' -exec grep -l video_decoder '{}' \;`
linux/drivers/media/video/v4l2-ioctl.c
linux/drivers/media/video/indycam.c
linux/drivers/media/video/saa7191.c
linux/drivers/media/video/vino.c

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-video.c
1df795370c1392a026c63816368108187aec2ec1 21-Feb-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (10692): usbvision: convert to v4l2_device/v4l2_subdev.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
6f2a278171bf7fc8153a42baa26b51d1ecb4c83f 20-Jan-2009 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (10306): usbvision: use usb_make_path to report bus info

usb_make_path reports canonical bus info. Use it when reporting bus info
in VIDIOC_QUERYCAP.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
be9ed5117d95cdc4e601f9da220ebeaaab131679 08-Jan-2009 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (10298): remove err macro from few usb devices

Patch removes err() macros from few usb devices.
It places pr_err in pvrusb2-v4l2.c, dev_err in dabusb and in usbvision
drivers. Beside placing dev_err, patch defines new s2255_dev_err macro
with S2255_DRIVER_NAME in s2255 module.

Signed-off-by: Alexey Klimov <klimov.linux@gmail.com>
Acked-by: Thierry Merle <thierry.merle@free.fr>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
cf8e193a48879a02f55b53c0cf2ec98a784baaa5 17-Jan-2009 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (10248): v4l-dvb: fix a bunch of compile warnings.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
2230c3c803a5f3a84f7c3bd86b8159a551edc8ca 03-Jan-2009 Julia Lawall <julia@diku.dk> V4L/DVB (10185): Use negated usb_endpoint_xfer_control, etc

This patch extends 134179823b3ca9c8b98e0631906459dbb022ff9b by using
usb_endpoint_xfer_control, usb_endpoint_xfer_isoc, usb_endpoint_xfer_bulk,
and usb_endpoint_xfer_int in the negated case as well.

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

// <smpl>
@@ struct usb_endpoint_descriptor *epd; @@

- (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_CONTROL\|0\))
+ !usb_endpoint_xfer_control(epd)

@@ struct usb_endpoint_descriptor *epd; @@

- (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_ISOC\|1\))
+ !usb_endpoint_xfer_isoc(epd)

@@ struct usb_endpoint_descriptor *epd; @@

- (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_BULK\|2\))
+ !usb_endpoint_xfer_bulk(epd)

@@ struct usb_endpoint_descriptor *epd; @@

- (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_INT\|3\))
+ !usb_endpoint_xfer_int(epd)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
aecde8b53b8ee1330a5a8206200f0d6b8845a6e0 30-Dec-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (10141): v4l2: debugging API changed to match against driver name instead of ID.

Since the i2c driver ID will be removed in the near future we have to
modify the v4l2 debugging API to use the driver name instead of driver ID.

Note that this API is not used in applications other than v4l2-dbg.cpp
as it is for debugging and testing only.

Should anyone use the old VIDIOC_G_CHIP_IDENT, then this will be logged
with a warning that it is deprecated and will be removed in 2.6.30.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
069b747931f13eda289c1d59a09ecc8162281a76 30-Dec-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (10138): v4l2-ioctl: change to long return type to match unlocked_ioctl.

Since internal to v4l2 the ioctl prototype is the same regardless of it
being called through .ioctl or .unlocked_ioctl, we need to convert it all
to the long return type of unlocked_ioctl.

Thanks to Jean-Francois Moine for posting an initial patch for this and
thus bringing it to our attention.

Cc: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
bec43661b1dc0075b7445223ba775674133b164d 30-Dec-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (10135): v4l2: introduce v4l2_file_operations.

Introduce a struct v4l2_file_operations for v4l2 drivers.

Remove the unnecessary inode argument.

Move compat32 handling (and llseek) into the v4l2-dev core: this is now
handled in the v4l2 core and no longer in the drivers themselves.

Note that this changeset reverts an earlier patch that changed the return
type of__video_ioctl2 from int to long. This change will be reinstated
later in a much improved version.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
134179823b3ca9c8b98e0631906459dbb022ff9b 30-Dec-2008 Julia Lawall <julia@diku.dk> V4L/DVB (10130): use USB API functions rather than constants

This set of patches introduces calls to the following set of functions:

usb_endpoint_dir_in(epd)
usb_endpoint_dir_out(epd)
usb_endpoint_is_bulk_in(epd)
usb_endpoint_is_bulk_out(epd)
usb_endpoint_is_int_in(epd)
usb_endpoint_is_int_out(epd)
usb_endpoint_is_isoc_in(epd)
usb_endpoint_is_isoc_out(epd)
usb_endpoint_num(epd)
usb_endpoint_type(epd)
usb_endpoint_xfer_bulk(epd)
usb_endpoint_xfer_control(epd)
usb_endpoint_xfer_int(epd)
usb_endpoint_xfer_isoc(epd)

In some cases, introducing one of these functions is not possible, and it
just replaces an explicit integer value by one of the following constants:

USB_ENDPOINT_XFER_BULK
USB_ENDPOINT_XFER_CONTROL
USB_ENDPOINT_XFER_INT
USB_ENDPOINT_XFER_ISOC

An extract of the semantic patch that makes these changes is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@r1@ struct usb_endpoint_descriptor *epd; @@

- ((epd->bmAttributes & \(USB_ENDPOINT_XFERTYPE_MASK\|3\)) ==
- \(USB_ENDPOINT_XFER_CONTROL\|0\))
+ usb_endpoint_xfer_control(epd)

@r5@ struct usb_endpoint_descriptor *epd; @@

- ((epd->bEndpointAddress & \(USB_ENDPOINT_DIR_MASK\|0x80\)) ==
- \(USB_DIR_IN\|0x80\))
+ usb_endpoint_dir_in(epd)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
af128a102c4aee994b4ff6e422b3cfab17127578 30-Oct-2008 Kay Sievers <kay.sievers@vrfy.org> V4L/DVB (9521): V4L: struct device - replace bus_id with dev_name(), dev_set_name()

This patch is part of a larger patch series which will remove
the "char bus_id[20]" name string from struct device. The device
name is managed in the kobject anyway, and without any size
limitation, and just needlessly copied into "struct device".

To set and read the device name dev_name(dev) and dev_set_name(dev)
must be used. If your code uses static kobjects, which it shouldn't
do, "const char *init_name" can be used to statically provide the
name the registered device should have. At registration time, the
init_name field is cleared, to enforce the use of dev_name(dev) to
access the device name at a later time.

We need to get rid of all occurrences of bus_id in the entire tree
to be able to enable the new interface. Please apply this patch,
and possibly convert any remaining remaining occurrences of bus_id.

We want to submit a patch to -next, which will remove bus_id from
"struct device", to find the remaining pieces to convert, and finally
switch over to the new api, which will remove the 20 bytes array
and does no longer have a size limitation.

Thanks,
Kay

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
f473bf76c71ca734a16f9331ce6b6e9603641888 01-Nov-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (9503): v4l: remove inode argument from video_usercopy

The inode argument was never used. Removing it from video_usercopy
brings the function pointer type of video_usercopy in line with similar
v4l2 functions, thus simplifying several drivers.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
c6330fb86fd0fed98b7e0d5792881a77b778fefc 19-Oct-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (9327): v4l: use video_device.num instead of minor in video%d

The kernel number of a v4l2 node (e.g. videoX, radioX or vbiX) is now
independent of the minor number. So instead of using the minor field
of the video_device struct one has to use the num field: this always
contains the kernel number of the device node.

I forgot about this when I did the v4l2 core change, so this patch
converts all drivers that use it in one go. Luckily the change is
trivial.

Cc: michael@mihu.de
Cc: mchehab@infradead.org
Cc: corbet@lwn.net
Cc: luca.risolia@studio.unibo.it
Cc: isely@pobox.com
Cc: pe1rxq@amsat.org
Cc: royale@zerezo.com
Cc: mkrufky@linuxtv.org
Cc: stoth@linuxtv.org
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-i2c.c
sbvision-video.c
a65e5d782f9db2a61a914dc01a329e0c2dcf92a1 09-Jul-2008 Johannes Berg <johannes@sipsolutions.net> remove CONFIG_KMOD from drivers

Straight forward conversions to CONFIG_MODULE; many drivers
include <linux/kmod.h> conditionally and then don't have any
other conditional code so remove it from those.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Cc: video4linux-list@redhat.com
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: linux-ppp@vger.kernel.org
Cc: dm-devel@redhat.com
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
sbvision-core.c
sbvision-video.c
a482f327ff56bc3cf53176a7eb736cea47291a1d 10-Oct-2008 Greg Kroah-Hartman <gregkh@suse.de> V4L/DVB (9116): USB: remove info() macro from usb media drivers

USB should not be having it's own printk macros, so remove info() and
use the system-wide standard of dev_info() wherever possible.

Cc: Douglas Landgraf <dougsland@gmail.com>
Cc: Mike Isely <isely@pobox.com>
Cc: Thierry Merle <thierry.merle@free.fr>
Cc: Antoine Jacquet <royale@zerezo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
c170ecf434bceb0e188b14a6deb3bfa3ec9ef699 23-Aug-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8788): v4l: replace video_get_drvdata(video_devdata(filp)) with video_drvdata(filp)

Use the new video_drvdata(filp) function where it is safe to do so.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
d56dc61265d2527a63ab5b0f03199a43cd89ca36 30-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8613): v4l: move BKL down to the driver level.

The BKL is now moved from the video_open function in v4l2-dev.c to the
various drivers. It seems about a third of the drivers already has a
lock of some sort protecting the open(), another third uses
video_exclusive_open (yuck!) and the last third required adding the
BKL in their open function.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
sbvision-video.c
0ea6bc8d43c9ee3c5384bea184eab020927a5b2c 26-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8523): v4l2-dev: remove unused type and type2 field from video_device

The type and type2 fields were unused and so could be removed.
Instead add a vfl_type field that contains the type of the video
device.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
f894dfd735237548d282d6fd55b6ebb4b2fd9ef2 25-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8488): videodev: remove some CONFIG_VIDEO_V4L1_COMPAT code from v4l2-dev.h

The video_device_create_file and video_device_remove_file functions can be
removed from v4l2-dev.h, removing the dependency on videodev.h in v4l2-dev.h.

Also removed a few more videodev.h includes that should have been videodev2.h.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
9c39d7eafa366b807067697f7fc5b14d8b865179 21-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8483): Remove obsolete owner field from video_device struct.

According to an old comment this should have been removed in 2.6.15.
Better late than never...

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
a399810ca69d9d4bd30ab8c1678c7439e567f90b 21-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8482): videodev: move all ioctl callbacks to a new v4l2_ioctl_ops struct

All ioctl callbacks are now stored in a new v4l2_ioctl_ops struct. Drivers fill in
a const struct v4l2_ioctl_ops and video_device just contains a const pointer to it.

This ensures a clean separation between the const ops struct and the non-const
video_device struct.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
38f9d308597fe3f8d52bfa30e7ed6c742b85a1db 23-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8477): v4l: remove obsolete audiochip.h

Converted the last users of audiochip.h to the v4l2-chip-ident.h header
and remove the now unused audiochip.h header.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
35ea11ff84719b1bfab2909903a9640a86552fd1 20-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8430): videodev: move some functions from v4l2-dev.h to v4l2-common.h or v4l2-ioctl.h

The functions in a header should not belong to another module. The prio functions
belong to v4l2-common.c, so move them to v4l2-common.h.

The ioctl functions belong to v4l2-ioctl.c, so create a new v4l2-ioctl.h header
and move those functions to it.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
22a04f106346c3af019135f2de3cabf9ac41c3ba 20-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8429): videodev: renamed 'class_dev' to 'dev'

The class_dev field is a normal device, not a class device. This is very
confusing and now that the old 'dev' field has been renamed to 'parent'
we can rename 'class_dev' to just 'dev'.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
5e85e732f0ed56aa97a3ba26ac2b93ffe597a208 20-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (8428): videodev: rename 'dev' to 'parent'

The field 'dev' is not the video device, but the parent of the video device.
Rename accordingly.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
f87086e302300fdff1bd32049deb7a7f3e3de7da 18-Jul-2008 Hans Verkuil <hverkuil@xs4all.nl> v4l-dvb: remove legacy checks to allow support for kernels < 2.6.10

Also remove some blank lines that were used to split compat code at -devel
tree.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
78b526a43561d7e5e702ba27948e422dfbc4bea1 28-May-2008 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (7949): videodev: renamed the vidioc_*_fmt_* callbacks

The naming for the callbacks that handle the VIDIOC_ENUM_FMT and
VIDIOC_S/G/TRY_FMT ioctls was very confusing. Renamed it to match
the v4l2_buf_type name.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
fdbbfb092cee0d826cba96df51f56c0e22cae579 06-May-2008 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (7846): Re-creates VIDEO_TUNER

VIDEO_TUNER is responsible for compilation of tuners.ko module. This were the
previous behaviour before the creation of MEDIA_TUNER.

Before this patch, tuner.ko were created even for drivers that don't need a
tuner (like webcam drivers).

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
config
149ef72deeba57078216c9fa678baff392295853 30-Apr-2008 Mauro Carvalho Chehab <mchehab@infradead.org> Rename common tuner Kconfig names to use the same
namespace for all of them.
config
7c91f0624a9a2b8b9b122cf94fef34bc7f7347a6 30-Apr-2008 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB(7767): Move tuners to common/tuners

There were several issues in the past, caused by the hybrid tuner design, since
now, the same tuner can be used by drivers/media/dvb and drivers/media/video.

Kconfig items were rearranged, to split V4L/DVB core from their drivers.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
akefile
df18c3196a1ec1db7a20997d3246a5a8cf535a77 05-Apr-2008 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (7503): usbvision: rename __PRETTY_FUNCTION__ occurrences

__PRETTY_FUNCTION__ has no sense in C lang context. Rename it as __func__

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
d2db42dd4eb53b86a40b96b0b12a7b2d12377bdd 05-Apr-2008 Harvey Harrison <harvey.harrison@gmail.com> V4L/DVB (7502): v4l: video/usbvision replace remaining __FUNCTION__ occurrences

__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
ff699e6bd02eb1c6d02c7c2b576c2ee6caab201c 22-Apr-2008 Douglas Schilling Landgraf <dougsland@gmail.com> V4L/DVB (7094): static memory

- Static memory is always initialized with 0.
- Replaced in some cases C99 comments for /* */

Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
c84e6036ba7177a404cc860cb5a440e06fad92dd 03-Feb-2008 Joe Perches <joe@perches.com> drivers/media/: Spelling fixes

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Adrian Bunk <bunk@kernel.org>
sbvision-video.c
6200bbaa5bd8b6751931364dfa4aa1cdd5efa686 10-Jan-2008 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (7024): usbvision: YUV to RGB conversion fixes

All YUV to RGB conversions in usbvision were reverted
(conversion to BGR but saying RGB to the application)

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Acked-by: Dwaine Garden <DwaineGarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
c6243d9c3de82e46467c88898db45ca14b6843a0 09-Jan-2008 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (6995): ubvision: add adjust_X_Offset/adjust_Y_Offset parms

Add adjust_X_Offset/adjust_Y_Offset module parameters to allow users
to tune X and Y picture offsets for their almost-working tuners without
repetitive recompilation.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
eeec4b3853a8af0cd2b42af24b9e8fd0e0ef1f8a 09-Jan-2008 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (6994): usbvision: add Pinnacle Studio PCTV USB (NTSC) FM V3

Add the "Pinnacle Studio PCTV USB (NTSC) FM" device.
This is the third occurrence of the same device designation...

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-cards.h
1fe934ddfc8e6e5663c0308ae216219be87b8d4f 12-Dec-2007 Daniel Walker <dwalker@mvista.com> V4L/DVB (6812): media: video: usbvision: remove ctrlUrbLock

The ctrlUrbLock has all it's users commented out, and so it's unused. This
patch removes it.

Signed-off-by: Daniel Walker <dwalker@mvista.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
544e6175330c86ad87abeeb1b048f56bafd96c31 12-Dec-2007 Andrew Morton <akpm@linux-foundation.org> V4L/DVB (6811): media-video-usbvision-add-mutex_unlock-to-error-paths-fix

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
0991112c1c4625323df8a582de1b2f8609922248 12-Dec-2007 Daniel Walker <dwalker@mvista.com> V4L/DVB (6810): media: video: usbvision: add mutex_unlock() to error paths

There are a few error paths which don't unlock the usbvision->lock.

So I've added mutex_unlock() calls to fix those paths.

Signed-off-by: Daniel Walker <dwalker@mvista.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
4c5efc1778387de98d5348666e7bc4396c9a5404 25-Nov-2007 Adrian Bunk <bunk@kernel.org> V4L/DVB (6665a): finish the VID_HARDWARE_* removal

This patch removes a few remainders of the VID_HARDWARE_* removal.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
643d01fb38b6f376cced035549f4e193018776e7
sbvision.h
289d4d2f0746715ada41e0945116eb3d62d5f35c 24-Oct-2007 Matthias Kaehlcke <matthias.kaehlcke@gmail.com> V4L/DVB (6400): usbvision: Convert the usbvision->lock semaphore to the mutex API

Convert the usbvision->lock semaphore to the mutex API

Signed-off-by: Matthias Kaehlcke <matthias.kaehlcke@gmail.com>
Reviewed-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
22c4a4e98ece0eaff13b3d0ac73c5283013eb6b1 15-Oct-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (6320): v4l core: remove the unused .hardware V4L1 field

struct video_device used to define a .hardware field. While
initialized on severl drivers, this field is never used inside V4L.
However, drivers using it need to include the old V4L1 header.

This seems to cause compilation troubles with some random configs.
Better just to remove it from all drivers.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
3be27d37c257fa5f99363f9c8e06e405cbad712e 13-Oct-2007 David Brownell <david-b@pacbell.net> i2c: Remove NOP i2c_algorithm.algo_control() methods

This removes NOP implementations of i2c_algorithm.algo_control.

With this change, there are no implementations of this hook in
the kernel.org tree ... that hook seems about ripe to remove.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
sbvision-i2c.c
54bd5b66c87d14e250f108aad1228b905d6882f6 08-Oct-2007 Kay Sievers <kay.sievers@vrfy.org> V4L/DVB (6293): V4L: convert struct class_device to struct device

The currently used "struct class_device" will be removed from the
kernel. Here is a patch that converts all users in drivers/media/video/
to struct device.

Reviewed-by: Thierry Merle <thierry.merle@free.fr>
Reviewed-by: Mike Isely <isely@pobox.com>
Reviewed-by: Luca Risolia <luca.risolia@studio.unibo.it>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
39f46adef8e83653b4716369683c134e1413ad30 09-Sep-2007 Jean Delvare <khali@linux-fr.org> V4L/DVB (6214): usbvision: Don't support I2C_M_REV_DIR_ADDR

I2C adapters should only support I2C_M_REV_DIR_ADDR if they really have
to (i.e. if they are connected to a broken I2C device which needs this
deviation from the standard I2C protocol.) As no media chip driver
uses I2C_M_REV_DIR_ADDR, I don't think that the usbvision driver needs
to support it.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
9c12224a607a4b22ab86784e3394b52810b9507c 21-Aug-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (6079): Cleanup: remove linux/moduleparam.h from drivers/media files

Since at least kernel 2.6.12-rc2, module.h includes moduleparm.h. This
patch removes all occurences of moduleparm.h from drivers/media files.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
ed4d6375a1498009a9e68d93661207351d36874f 26-Sep-2007 Al Viro <viro@ftp.linux.org.uk> usbvision-video: buggered method tables

duplicated .mmap in one, .vidioc_s_audio misspelled as .vidioc_g_audio
in other

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-video.c
248bdd5efca5a113cbf443a993c69e53d370236b 19-Sep-2007 Kees Cook <kees@ubuntu.com> pci: fix unterminated pci_device_id lists

Fix a couple drivers that do not correctly terminate their pci_device_id
lists. This results in garbage being spewed into modules.pcimap when the
module happens to not have 28 NULL bytes following the table, and/or the
last PCI ID is actually truncated from the table when calculating the
modules.alias PCI aliases, cause those unfortunate device IDs to not
auto-load.

Signed-off-by: Kees Cook <kees@ubuntu.com>
Acked-by: Corey Minyard <minyard@acm.org>
Cc: David Woodhouse <dwmw2@infradead.org>
Acked-by: Jeff Garzik <jeff@garzik.org>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-cards.c
bc147135bc410bdd9da684646af75a188d882d56 23-Jul-2007 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (5900): usbvision: fix bugs [sg]_register functions

s_register was assigning the return code to (unsigned)reg->val, rather than
errCode, which it what it would return. Except reg->val can't be < 0, so it
would never actually return an error.

g_register never actually put the value it read into reg->val.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
66a17879e9f18a38c4ca5e6ba600a3f5b1b51188 26-Jun-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5826): Usbvision: video mux cleanup

- usbvision_muxsel simplified, now uses some well known constants.
- since the decoder needs to change input norm, call to muxsel added when
changing video standard.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Acked-by: Dwaine Garden <DwaineGarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
ffddcaa6ec4e85ed8504deac1f51f44c86ec1d23 30-Jun-2007 Matthew Garrett <mjg59@srcf.ucam.org> V4L/DVB (5825): Alter the tuner type for the WinTV USB UK PAL model.

Alter the tuner type for the WinTV USB UK PAL model.

Signed-off-by: Matthew Garrett <mjg59@srcf.ucam.org>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
a1bad7773e562f331b5951def24f73c38579e0cb 26-Jun-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5824): Usbvision: Hauppauge WinTV USB SECAM_L fix

- Hauppauge WinTV USB SECAM_L fixed (needed some picture X and Y shiftings)

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
805b35634b6c349738664619a6d2eb8ece02fe63 28-May-2007 Robert P. J. Day <rpjday@mindspring.com> V4L/DVB (5704): Remove worthless references to obsolete MODULE_PARM macro.

Remove the long-dead references to the obsolete MODULE_PARM macro.
Given that the first one of those is actually misspelled as
"MODULE_PARAM", it's clear that they can't have been doing any good.
Acked-by: Thierry Merle <thierry.merle@free.fr>

Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
c5f48367fe54c46805774eeea8e828de54a5ad7b 08-May-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5644): Usbvision: video_ioctl2 conversion

The ioctl entry point, a big switch/case, is splitted in little
functions.

These functions are set as callbacks for the video_ioctl2 video4linux
facility.

This improves the driver memory consumption and enables the v4l1
compatibility as a side effect.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Acked-by: Dwaine P. Garden <dwainegarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
ea1f83cee96badc28d3f67ef29ac29c9d0eb0a1b 02-May-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5643): Usbvision: make common video and radio ioctls

Radio and video ioctls are the same,
delete the usbvision_do_radio_ioctl function
add the special cases for radio in usbvision_v4l2_do_ioctl

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
8c7189d1939f6e15c4ebc23a98b3b9f34bd004d7 30-Apr-2007 David Warman <dwarman@davidwarman.net> V4L/DVB (5642): add comment that VO_MODE is also being set.

usbvision_set_video_format: add comment that VO_MODE is also being set.

Signed-off-by: David Warman <dwarman@davidwarman.net>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
9fe01e5c297e716c6b50166c3c032a6c07604e5b 30-Apr-2007 David Warman <dwarman@davidwarman.net> V4L/DVB (5641): change VideoNorm to NTSC for Belkin USB Videobus II

Signed-off-by: David Warman <dwarman@davidwarman.net>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
fe818d1d9a50930aa7e1ce7169fb42e1e0c45882 27-May-2007 Thierry Merle <thierry.merle@free.fr> V4L/DVB (5720): Usbvision: fix urb allocation and submits

- fixed the urb allocation part that was not taking into account the current alternate setting
this fixes usb_submit_urb returning -90 errno in isocIrq.
- fixed usb_submit_urb returning -1 errno in isocIrq (need to ignore usb urb with status==-ENOENT)
Acked-by: Dwaine P. Garden <dwainegarden@rogers.com>

Signed-off-by: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
c5da5afb9d7b244cfe3334c77e90b4296cf5f263 02-May-2007 Jan Engelhardt <jengelh@linux01.gwdg.de> V4L/DVB (5586): Use menuconfig objects II - V4L

Change Kconfig objects from "menu, config" into "menuconfig" so
that the user can disable the whole feature without having to
enter the menu first.

Signed-off-by: Jan Engelhardt <jengelh@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
config
e63340ae6b6205fef26b40a75673d1c9c0c8bb90 08-May-2007 Randy Dunlap <randy.dunlap@oracle.com> header cleaning: don't include smp_lock.h when not used

Remove includes of <linux/smp_lock.h> where it is not used/needed.
Suggested by Al Viro.

Builds cleanly on x86_64, i386, alpha, ia64, powerpc, sparc,
sparc64, and arm (all 59 defconfigs).

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-core.c
sbvision-video.c
7c59b6615fed9d3006b1e7b865fb07e483129611 01-May-2007 Jean Delvare <khali@linux-fr.org> i2c: Cleanup the includes of <linux/i2c.h>

Clean up the includes of <linux/i2c.h>. Only include this header file
when we actually need it.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
sbvision-cards.c
ec709bb801a98dcac0a95c060c431eda73e31587 17-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5530): Usbvision: remove CustomDevice facility

usbvision has a module parameter that ables the user to add a new USB
entry at driver load. This functionality is useless by experience
(adding statically the entry is easy).

Furthermore, the USB_DEVICE(0xfff0, 0xfff0) USB entry caused
usbvision_probe to be called for all unclaimed devices.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Acked-by: Dwaine Garden <DwaineGarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-cards.h
sbvision-video.c
6284feafcf589103f4a85d98d305e7a9d98970d3 16-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5529): Usbvision: remove not needed TUNER_SET_TYPE_ADDR call

usbvision_i2c: remove TUNER_SET_TYPE_ADDR call in attach_inform
since it is done by tuner_core.
Acked-by: Dwaine Garden <DwaineGarden@rogers.com>

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
bf8b20e190f9878978117e39e9a4e493a2e9d6bd 16-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5528): Usbvision: reverting some i2c cleanups

usbvision-i2c.c: reverting some i2c cleanups in order to recover a safe state.
Acked-by: Dwaine Garden <DwaineGarden@rogers.com>

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
3153bd91bfe14b6b93aef5b6b7c9fc279eec60d9 15-Apr-2007 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (5525): Usbvision: fix confusion over 7-bit vs 8-bit TDDA9887 addresses

The code was testing an 8-bit address against a 7-bit address. Will the
confusion of the two never cease?
Biggest flaw of the I2C protocol: the R/W bit is the LSB instead of the
MSB. No one can ever agree if addresses are 7-bits and the R/W bit
follows them, or if they are 8-bit and the R/W bit is OR-ed into the
address byte. If the R/W bit was first, it wouldn't make any difference!

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
f2c340583c27f2f93ed1c720ae863ea601e1d74a 15-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5524): Usbvision: fix TDA9887 detection

- Adding 0x86 as possible I2C addresses for TDA9887 to call TUNER_SET_TYPE_ADDR.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
672d013bed5e144ac641db343251e35d3212c9ad 14-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5523): Usbvision: fix a debug message in usb probe function

- change a printk to PDEBUG when USB probe detects an unknown device.
This will avoid a message log from usbvision when an unclaimed device is inserted.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
1ff16c2091a557f8080eb62c087465a87e4330e9 14-Apr-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5522): Usbvision: i2c function cleanups

usbvision-i2c function renamings, code cleanup

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
d3df9c4fa13db14cb9f6cd4cf31bd2a61c0e9911 14-Apr-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (5521): Usb_get_dev were called twice. Removing the extra call.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
f8a389db502f7b287903b209f925df5570ff5478 14-Apr-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (5518): Fix a bug on device detection

Thanks to: Thierry MERLE <thierry.merle@free.fr> for pointing this

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-cards.h
sbvision-video.c
c682b3a7fb8ec69ac73511bbb6a378e40aa35f35 14-Apr-2007 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (5517): Usbvision: store the device database more efficiently

One bit wide bitfields need to declared unsigned to have the range 0 to
1, or they have the range -1 to 0.

A few techniques to reduce the driver's size by about 1700 bytes on ia32,
probably more on x86-64.

Put the biggest fields first, less padding is necessary that way.

Put fields with a limited range into a smaller type. For example
VideoChannels will fit in 3 bits, and TunerType can use 8 bits.

Vin_Reg1, Vin_Reg2, and Dvi_yuv define values for 8-bit registers, but
they can't just go into an 8-bit field with no changes, since -1 was used
as a flag to indicate a value was not present. So what we do is create a
one-bit flag for each one to indicate if a value is or is not present.

This only takes 9 bits and has the added advantage that when the register
isn't overridden (Vin_Reg[12] never are) it doesn't need to appear in the
structure definition since the default value for the flag will be zero.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Acked-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-core.c
sbvision-video.c
sbvision.h
f7ca6256bc1db4fb44adda99e082f8c80ada8957 14-Apr-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (5516): Reduce usbvision data size

This patch reduces usbvision driver on about 1Kb on i386 over the
original version with the old struct:
text data bss dec hex filename
52312 11848 60 64220 fadc old/usbvision.ko
52474 10708 60 63242 f70a new/usbvision.ko

Acked-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-video.c
sbvision.h
659ae56dcd5a50e4560cb526a0e0dc881418dad4 14-Apr-2007 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (5515): Use a better format to represent usbvision supported boards

Changed usbvision cards table to allow:
1) Not repeat USB ID on two structs;
2) Not need to specify both usb and card description tables at
the same order, removing some magic;
Some cards had duplicated names. Fixed.
A test for an specific board were doing by using a string comparation.
The comparation were wrong. Also, it is not a good practice to recognize
a board based on his string name.
Acked-by: Thierry MERLE <thierry.merle@free.fr>

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-cards.h
sbvision-video.c
sbvision.h
e6c1df5581320720b8212a543e055e19d46f32bb 06-Mar-2007 Dwaine P. Garden <DwaineGarden@rogers.com> V4L/DVB (5386): Add some missing Hauppauge and Belkin devices to the driver

-Add some missing Hauppauge and Belkin devices to the driver.
-Fixed up some device descriptions.

Signed-off-by: Dwaine P. Garden <DwaineGarden@rogers.com>
Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
f3d092b84a855c44914fea0648695bef7d751266 24-Feb-2007 Hans Verkuil <hverkuil@xs4all.nl> V4L/DVB (5304): Improve chip matching in v4l2_register

The chip matching in struct v4l2_register for VIDIOC_DBG_G/S_REGISTER
was rather primitive. It could not be extended to other busses besides
i2c and it lacked a way to.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
2a9f8b5d25beacd034369fca416b548cbf931561 07-Feb-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5206): Usbvision: set alternate interface modification

- usb alternate selection modified to get the biggest endpoint packet size.
- fix sysfs get values for brightness/contrast/hue/saturation

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
config
sbvision-core.c
sbvision-video.c
sbvision.h
6f78e186fe5d29dbff5e34f950adb573c4808de4 07-Feb-2007 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5205): Usbvision: dynamic allocation for frames

- fix decoder route output
- dynamic frame buffer allocation

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
62d50addf0774115adaa9e01e09099c3d7daa13d 31-Jan-2007 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (5163): Add checks for CAP_SYS_ADMIN to VIDIOC_DBG_G_REGISTER

Before, root privileges were only needed to set hardware registers, not
to read them. On some hardware, reading from the wrong place at the
wrong time can hang the machine. So, to be consistent, root privileges
are required to read registers on all hardware.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
52ebc763d8e0c9f2ab48af89a75e90e2318bac86 24-Jan-2007 Trent Piepho <xyzzy@speakeasy.org> V4L/DVB (5146): Make VIDIOC_INT_[SG]_REGISTER ioctls no longer internal only

The direct register access ioctls were defined as kernel internal only,
but they are very useful for debugging hardware from userspace and are
used as such. Officially export them.

VIDIOC_INT_[SG]_REGISTER is renamed to VIDIOC_DBG_[SG]_REGISTER
Definition of ioctl and struct v4l2_register is moved from v4l2-common.h
to videodev2.h.

Types used in struct v4l2_register are changed to the userspace
exportable versions (u32 -> __u32, etc).

Use of VIDIOC_DBG_S_REGISTER requires CAP_SYS_ADMIN permission, so move
the check into the video_ioctl2() dispatcher so it doesn't need to be
duplicated in each driver's call-back function. CAP_SYS_ADMIN check is
added to pvrusb2 (which doesn't use video_ioctl2).

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
de6a1b8edc48155249896f2600398e139f4860c6 08-Jan-2007 Dwaine Garden <dwainegarden@rogers.com> V4L/DVB (5032): Improves some USBVision info messages

Replaces the info statements with printk(KERN_INFO statements.
This will cut down on the useless information which is showing up
in the kernel messages log file.

Signed-off-by: Dwaine P. Garden <DwaineGarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
4a06b538d6c7c1713d759f79b4fbd1d91d4932ca 29-Dec-2006 Adrian Bunk <bunk@stusta.de> V4L/DVB (5018): Make usbvision_rvfree() static

usbvision_rvfree() can now become static.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
cd354f1ae75e6466a7e31b727faede57a1f89ca5 14-Feb-2007 Tim Schmielau <tim@physik3.uni-rostock.de> [PATCH] remove many unneeded #includes of sched.h

After Al Viro (finally) succeeded in removing the sched.h #include in module.h
recently, it makes sense again to remove other superfluous sched.h includes.
There are quite a lot of files which include it but don't actually need
anything defined in there. Presumably these includes were once needed for
macros that used to live in sched.h, but moved to other header files in the
course of cleaning it up.

To ease the pain, this time I did not fiddle with any header files and only
removed #includes from .c-files, which tend to cause less trouble.

Compile tested against 2.6.20-rc2 and 2.6.20-rc2-mm2 (with offsets) on alpha,
arm, i386, ia64, mips, powerpc, and x86_64 with allnoconfig, defconfig,
allmodconfig, and allyesconfig as well as a few randconfigs on x86_64 and all
configs in arch/arm/configs on arm. I also checked that no new warnings were
introduced by the patch (actually, some warnings are removed that were emitted
by unnecessarily included header files).

Signed-off-by: Tim Schmielau <tim@physik3.uni-rostock.de>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
12a917f69d1468c91d646dbad8408dd0d39d6207 13-Feb-2007 Jean Delvare <khali@linux-fr.org> i2c: Declare more i2c_adapter parent devices

Declare the parent device of i2c_adapter devices each time we can
easily do so. It makes the i2c_adapter appear at the right place in
the device tree, rather than as a platform device.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: David Brownell <dbrownell@users.sourceforge.net>
Cc: Len Brown <len.brown@intel.com>
Cc: Jordan Crouse <jordan.crouse@amd.com>
Cc: Jody McIntyre <scjody@modernduck.com>
Cc: Stefan Richter <stefanr@s5r6.in-berlin.de>
Cc: v4l-dvb-maintainer@linuxtv.org
Cc: Petr Vandrovec <vandrove@vc.cvut.cz>
sbvision-i2c.c
fa027c2a0a0d6d1df6b29ee99048502c93da0dd4 12-Feb-2007 Arjan van de Ven <arjan@linux.intel.com> [PATCH] mark struct file_operations const 4

Many struct file_operations in the kernel can be "const". Marking them const
moves these to the .rodata section, which avoids false sharing with potential
dirty data. In addition it'll catch accidental writes at compile time to
these shared resources.

[akpm@sdl.org: dvb fix]
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-video.c
8a5ab4157b3933d4fa29a1612879ab08f681041a 09-Feb-2007 Al Viro <viro@ftp.linux.org.uk> [PATCH] usbvision missing __user

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
sbvision-video.c
c430ca1e16b2b4b30f567806c73e270caea8db1d 30-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (5019): Fix the frame->grabstate update in read() entry point.

The Coverity checker spotted that in usbvision_v4l2_read(), the variable
"frmx" is never assigned any value different from -1, but it's used an
an array index in "usbvision->frame[frmx]".
Thanks to Adrian Bunk <bunk@stusta.de> for warning about that.

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
70bdd9c83a6e757e5fb9cc3195f27d2c1d0a4c39 26-Dec-2006 Alexey Dobriyan <adobriyan@gmail.com> V4L/DVB (5012): Usbvision fix: It was using "&&" instead "&"

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
ed00b41dc8bc286682d31ad64060ccc70513e90b 27-Dec-2006 Dwaine Garden <DwaineGarden@rogers.com> V4L/DVB (4979): Fixes compilation when CONFIG_V4L1_COMPAT is not selected

- SYSFS: Replaced all to_video_device(cd), video_device_create_file,
video_device_remove_file and add the proper checks at create_file
- Converted old norm values to V4L2 ones.
- Robustness on sysfs hue/contrast/saturation queries.
Additional check in order to return 0 if the driver is not opened.
- Whitespace cleanups in usbvision-cards.c

This patch merges two fixes by Thierry MERLE and Mauro Chehab, and adds
additional checks.

Signed-off-by: Dwaine Garden<DwaineGarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-video.c
38284ba361d69eca34a3bfc553ebfac81fea2698 15-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4970): Usbvision memory fixes

- fix decompression buffer allocation not done at first driver open
- simplification of USB sbuf allocation (use of usb_buffer_alloc)
- replaced vmalloc by vmalloc_32 (for homogeneity)
- add of saa7111 (i2cAddr=0x48) detection printout in attach_inform

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
c6268461473e1c62e31afde657069c050ee8dea7 11-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4960): Removal of unused code from usbvision-i2c.c

i2c_adap is almost not used. This patch removes it, cleaning the i2c support,
and improving driver understanding.
Thanks to Thierry Merle for testing it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
sbvision.h
0a0ceadebd4551c26110f5daf0b38d9054674c9e 11-Dec-2006 Adrian Bunk <bunk@stusta.de> V4L/DVB (4959): Usbvision: possible cleanups

This patch contains the following possible cleanups:
- make needlessly global functions static
- remove the unused EXPORT_SYMBOL's

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
sbvision.h
2a7e9a260ede3b17b5bc25c540a033a45bbf0461 11-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4954): Fix: On ia64, i2c adap->inb/adap->outb are wrongly evaluated

i2c defines two callbacks (inb/outb). On ia64, since it defines also two macros
with those names, it causes the following errors:
drivers/media/video/usbvision/usbvision-i2c.c:64:39: macro "outb" passed 4 arguments, but takes just 2
drivers/media/video/usbvision/usbvision-i2c.c: In function `try_write_address':
drivers/media/video/usbvision/usbvision-i2c.c:64: warning: assignment makes integer from pointer without a cast
drivers/media/video/usbvision/usbvision-i2c.c:89:38: macro "inb" passed 4 arguments, but takes just 1
drivers/media/video/usbvision/usbvision-i2c.c: In function `try_read_address':
drivers/media/video/usbvision/usbvision-i2c.c:89: warning: assignment makes integer from pointer without a cast
drivers/media/video/usbvision/usbvision-i2c.c:85: warning: unused variable `buf'
drivers/media/video/usbvision/usbvision-i2c.c:173:53: macro "inb" passed 4 arguments, but takes just 1
drivers/media/video/usbvision/usbvision-i2c.c: In function `usb_xfer':
drivers/media/video/usbvision/usbvision-i2c.c:173: warning: assignment makes integer from pointer without a cast
drivers/media/video/usbvision/usbvision-i2c.c:179:54: macro "outb" passed 4 arguments, but takes just 2
drivers/media/video/usbvision/usbvision-i2c.c:179: warning: assignment makes integer from pointer without a cast
thanks to Andrew Morton for pointing this.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-i2c.c
1de1bf06330920802d3b7646a088965bdd918356 10-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB 4949b: Fix container_of pointer retreival

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
67952e8cb111c5b2f9e675dba1bbde4876f9fcf3 10-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4949a): Fix INIT_WORK

INIT_WORK syntax changed on kernel 2.6.19. Fixing it on
usbvision and cx88-input.


Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
c876a3468d0f136710af81595177889953d1ff71 09-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4953): Usbvision minor fixes

- fix debug outputs
- fix returned parameters on VIDIOC_G_FMT, VIDIOC_S_FMT and
VIDIOC_TRY_FMT and mmap size setting

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-video.c
sbvision.h
f30ebd43597e9b2bbbc8b0eb650f5aad545e255b 09-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4951): Add version.h, since it is required for VIDIOC_QUERYCAP

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-video.c
a1ed551cdb4f29157466340760fde68bcda704a9 09-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4941): Remove LINUX_VERSION_CODE and fix identations


Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision-video.c
7ca659e3c1c3dd67073751385ae3bd25b27526bb 09-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4942): Whitespace cleanups

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-cards.c
sbvision-core.c
sbvision-video.c
483dfdb64fd4a9f240c84e0e225a90c044d65402 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4937): Usbvision cleanup and code reorganization

- removal of overlay stuff
- reorganization of functions in 3 files:
* usbvision-i2c for I2C-related stuff
* usbvision-video for v4l2 entry points
* usbvision-core for all peripheral controls and utilities

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
akefile
sbvision-cards.c
sbvision-core.c
sbvision-i2c.c
sbvision-i2c.h
sbvision-video.c
sbvision.h
d8159a3684007e0ded915cb7465c9534a2650c53 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4936): Make MT4049FM5 tuner to set FM Gain to Normal

- remove any specific TDA9887_SET_CONFIG of usbvision driver
- add fm_gain_normal=1 to the MT4049FM5 tuner for radio functionality

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
cefccc8011c58b559498396f0ccefa0a0ffa3f53 04-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4934): Usbvision radio requires GainNormal at e register

Adds an option to select GainNormal at tda9887 and make usbvision
to use it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
3086d6cb0a2ec93f17bc215af3113c54af6080c1 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4933): Usbvision_v4l2: radio interface / tda9887 problem ?

- implement the v4l2 radio interface

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
957883d0b56a649389d0652a727324dd8ba2e83c 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4932): Usbvision_v4l2: fix norm setting problems

Patch contents:
- fix i2c command broadcast (caused problems for SECAM norm setting)
- default input selection at driver open

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
ee5407c5019eb720872abea2e0a1376c35e2304a 04-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4931): Removed usbvision_ioctl.h, since it isn't required anymore

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision_ioctl.h
40bad67840aa6856cb39a431510a57d940017898 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4930): Usbvision_v4l2 : mmap corrected to get all frames

- private ioctls UVIOCSREG/UVIOCGREG translated to the
VIDIOC_INT_G_REGISTER/VIDIOC_INT_S_REGISTER
- lost frame bug corrected (mmap rework)
- reset scratch buffer is no buffer is queued (prevents useless scratch
overflow management)

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
3084920b555b3ba73590430b2e03d9167db23e8e 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4929): Read() implementation + format set/get simplifications

- implement read() entry point that works with linux list.h
- rework of VIDIOC_ENUM_FMT/VIDIOC_S_FMT/VIDIOC_G_FMT
- VIDIOC_STREAMON : allows streaming whereas there is no queued buffer
(xdtv does VIDIOC_STREAMON before VIDIOC_QBUFs)

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
5f7fb877be14da92803f0b5b60955e071ebe2d58 04-Dec-2006 Thierry <thierry.merle@free.fr> V4L/DVB (4928): Usbvision_v4l2 robustness on disconnect

This patch corrects 2 bugs (causes kernel oops) that occur when
unplugging the peripheral whereas nobody has opened it yet :
- do not call usbvision_stop_isoc if usbvision_init_isoc has not been called
- do not call wakeup_interruptible on waitqueues that did not have been
initialized with init_waitqueue_head

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision.h
f2242ee5474f46d87a45cd4e214b5c3aa02ff293 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4927): Enhancements on usbvision driver

Enhance the buffer management of this driver + some corrections
- linux list.h usage for buffer management
- VIDIOC_ENUMSTD/VIDIOC_G_STD/VIDIOC_S_STD simplification (use of
v4l2_video_std_construct)
- create_sysfs : remove of warnings for video_device_create_file return code
- make the driver compatible with 2.6.19 kernel version (remove
slave_send and slave_recv in usbvision-i2c, change ctrlUrb_complete
function prototype)
- deactivated v4l2_read because this code was not the priority but
working on it :)

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
sbvision.h
18d8a4540caddaa9a42fb4dbc04c75c4b806278b 04-Dec-2006 Dwaine Garden <dwainegarden@rogers.com> V4L/DVB (4926): Fix USBVision handling of VIDIOC_QUERYCTRL

There's a better (and recommended) way for handling VIDIOC_QUERYCTRL.

This patch will fix the issue where the hardware control values were
invalid and stops the SAA7115 module from complaining about invalid values.

saa7115 4-0024: invalid brightness setting 32768
saa7115 4-0024: invalid contrast setting 49152
saa7115 4-0024: invalid hue setting 32768
saa7115 4-0024: invalid saturation setting 32768

Signed-off-by: Dwaine Garden <dwainegarden@rogers.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
cc9e595a585a4f067dcfdc67e7c4432702ea28ac 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4925): Corrected and separated the Kconfig for usbvision

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
config
c8400c700723936d9333c977e51fa77062d26dd4 04-Dec-2006 Thierry MERLE <thierry.merle@free.fr> V4L/DVB (4924): Fix some bugs on usbvision due to the merge into one module

Found the bug that prevented the driver from loading : a module
param conflict between usbvision-i2c and usbvision-core (debug
parameter).
- correct the module param "debug" conflics in usbvision-i2c.c and
usbvision-core.c
- add some debug printouts in usbvision-core.c VDIOC_QBUF/VIDIOC_DQBUF
- usbvision-core.c : add vb->field = V4L2_FIELD_NONE in VIDIOC_DQBUF

Signed-off-by: Thierry MERLE <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
sbvision-core.c
sbvision-i2c.c
6714b01263b06b2e7d054625486451a9fd8e03f4 04-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4923): Splitted usbvision cards from usbvison.h

Having the cards description into a separated file makes
easier to maintain and follows the same standard as other
drivers.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
akefile
sbvision-cards.c
sbvision-core.c
sbvision.h
781aa1d1ab7ba13314af0af6c5d70c0eb0e96bf4 04-Dec-2006 Mauro Carvalho Chehab <mchehab@infradead.org> V4L/DVB (4922): Add usbvision driver

This patch adds usbvision into V4L/DVB HG tree.
Usbvision driver is a GPL driver, made by:
Joerg Heckenbach <joerg@heckenbach-aw.de>
and
Dwaine Garden <DwaineGarden@rogers.com>
V4L2 migration made by:
Thierry Merle <thierry.merle@free.fr>
Kconfig/Makefile scripts by:
Mauro Carvalho Chehab <mchehab@infradead.org>

Signed-off-by: Joerg Heckenbach <joerg@heckenbach-aw.de>
Signed-off-by: Dwaine Garden <dwainegarden@rogers.com>
Signed-off-by: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
akefile
sbvision-core.c
sbvision-i2c.c
sbvision-i2c.h
sbvision.h
sbvision_ioctl.h