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

2713 Commits

Author SHA1 Message Date
Robert P. J. Day 0c71bf1c30 V4L/DVB (5739): Replace C code with calls to ARRAY_SIZE macro.
Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:52 -03:00
Michael Krufky e0099e9eda V4L/DVB (5734): Cx88: kill dev->fw_size
Now that cx88-blackbird is only accepting the official firmware image,
we no longer have any need to store the size of the firmware inside the
cx88 data structure.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:52 -03:00
Hans Verkuil 2547223732 V4L/DVB (5733): Blackbird should accept only new cx2341x encoding firmwares
Remove temporary support for older 256 kB firmwares.
ivtv, pvrusb2 and blackbird can now all handle the newer larger firmwares,
so support for the older (buggier) firmware can be removed.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:51 -03:00
Hans Verkuil a957641bba V4L/DVB (5729): Remove support for 256 Kb firmware files.
For backwards compatibility firmware files of 256 Kb were allowed: all
drivers have now been updated to support the newer larger firmwares so
remove this compatibility code and only support the newer firmware.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:50 -03:00
Mauro Carvalho Chehab 74fa39e590 V4L/DVB (5727): Remove VIVI_SCATTER
vivi scatter method were used as a proof of concept. It can be
safelly removed from mainstream, since the current method is
faster and better than the previous solution.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:49 -03:00
Christoph Hellwig 3e0e38e6e4 V4L/DVB (5724): Saa7134-tvaudio: kthread conversion
Acked-by: Hermann Pitton <hermann-pitton@arcor.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:48 -03:00
Michael Krufky b208319993 V4L/DVB (5719): Tuner: Move device-specific private data out of tuner struct
Create private data struct for device specific private data.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:48 -03:00
Michael Krufky 56584c9ea9 V4L/DVB (5718): Mt20xx: whitespace cleanup
replace leading spaces with tabs

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:47 -03:00
Douglas Schilling Landgraf 2e02b9a717 V4L/DVB (5705): Removed unnecessary .hardware from video_device struct.
From: Douglas Schilling Landgraf <dougsland@gmail.com>

Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:47 -03:00
Robert P. J. Day 805b35634b 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>
2007-07-18 14:23:46 -03:00
Dmitry Torokhov 2c8a3a3355 V4L/DVB (5698): Input: drivers/media - switch to using input_dev->dev.parent
In preparation for struct class_device -> struct device input
core conversion switch to using input_dev->dev.parent when
specifying device position in sysfs tree.

Signed-off-by: Dmitry Torokhov <dtor at mail.ru>
Acked-by: Thierry Merle <thierry.merle@free.fr>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:46 -03:00
Aapo Tahkola d577ee004d V4L/DVB (5696): M920x: add missing error handling to prevent syslog spamming
Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:44 -03:00
Aapo Tahkola 3ab3b69de5 V4L/DVB (5695): M920x: enable second adapter on LifeView TV Walker Twin
Enable second adapter on LifeView TV Walker Twin DVB-T USB2.0

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:44 -03:00
Aapo Tahkola 3847b22ab5 V4L/DVB (5694): M920x: fix for Dposh devices
Make sure devices manufactured by Dposh are not affected by previous hw 
pid filtering changes

Doing so might crash it.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:43 -03:00
Aapo Tahkola 55bbe5ea20 V4L/DVB (5693): M920x: second endpoint also needs to be changed to alt setting
Spotted by Jeremy Nysen.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:39 -03:00
Aapo Tahkola 47f8df0fc0 V4L/DVB (5692): M920x: attempt to fix hw pid filters on second endpoint
Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:38 -03:00
Daniel Gimpelevich 7cb47a1460 V4L/DVB (5685): Cx88: add support for ADS Tech Instant Video PCI
Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:37 -03:00
Dmitry Torokhov 8083c5200e V4L/DVB (5684): V4L: ir-kbd-i2c - switch to using msecs_to_jiffies()
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:36 -03:00
Dmitry Torokhov 749823a06e V4L/DVB (5683): V4L: cx88 - switch to using msecs_to_jiffies()
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:36 -03:00
Dmitry Torokhov b4ba788425 V4L/DVB (5682): SAA7134 - switch to use msecs_to_jiffies()
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:35 -03:00
Mauro Carvalho Chehab c57032decd V4L/DVB (5681): Correct aliases for STD/L and STD/Lc
Some macros were using very weird names, like PAL/L (this std doesn't
exist). Fixing it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:34 -03:00
Akinobu Mita 783aa8fa1f V4L/DVB (5678): Zr364xx: fix return values
This patch fixes several return value related problems in zr364xx.

- return -ENOMEM instead of -ENODEV on out of memory

- zr364xx checks video_register_device() error only when
  its return value is -1. But video_register_device() doesn't
  always return -1 on error.

- If usb_register() returns error, module_init() wrongly returns 1:
	retval = usb_register(&zr364xx_driver) < 0;
	...
	return retval;

  And it allows the module to be loaded. Because sys_init_module() doesn't
  see positive return value as error.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Antoine Jacquet <royale@zerezo.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:33 -03:00
Hans Verkuil 1b9d313c38 V4L/DVB (5674): Models 30012-30039 are for a low profile PVR250, not PVR150.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:32 -03:00
Hans Verkuil e80666b87b V4L/DVB (5671): Autodetect new PVR150 low profile cards.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:31 -03:00
Oliver Endriss f72ce64447 V4L/DVB (5669): Budget-av: Add support for EasyWatch DVB-S (0x1894:0x001b)
Add support for Satelco EasyWatch PCI DVB-S card (subsystem 0x1894:0x001b).

Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:31 -03:00
Michael Krufky 7b68814d79 V4L/DVB (5637): Cx88: kill core->pll_desc and core->pll_addr
Now that dvb-pll is being used properly in all cx88-dvb instances,
the cx88 driver no longer needs to store pll_desc nor pll_addr.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:30 -03:00
Trent Piepho b7754d74d2 V4L/DVB (5636): Integrate all users of the fmd1216 tuner with dvb-pll
Enhance the dvb-pll definition of the fmd1216 tuner by adding an init sequence
and a sleep sequence.

The init sequence sets the AGC control register to 0xa0, selecting the fast
time constant and 112 dBuV take-over point.  This the recommended value for
DVB-T operation.

The sleep sequence sets bit P4 (which is believed to turn the analog
demodulator on), turns off the tuning voltage, and sets the AGC control
register to 0x60 (external AGC voltage, the recommended value for analog
operation).

The existing dvb-pll users in the cx88 driver, listed below, will gain these
init and sleep sequences.

CX88_BOARD_HAUPPAUGE_HVR1100    Hauppauge WinTV-HVR1100 DVB-T/Hybrid
CX88_BOARD_HAUPPAUGE_HVR1100LP  Hauppauge WinTV-HVR1100 DVB-T/Hybrid (Low Profi
CX88_BOARD_WINFAST_DTV2000H     WinFast DTV2000 H
CX88_BOARD_HAUPPAUGE_HVR3000    Hauppauge WinTV-HVR3000 TriMode Analog/DVB-S/DV
CX88_BOARD_HAUPPAUGE_HVR1300    Hauppauge WinTV-HVR1300 DVB-T/Hybrid MPEG Encod

This non-dvb-pll user in the cx88 driver should only gain the sleep sequence,
as it already had an equivalent init sequence.  The non-dvb-pll code for this
user is removed.

X88_BOARD_DNTV_LIVE_DVB_T_PRO   digitalnow DNTV Live! DVB-T Pro

In these saa7134 driver, these non-dvb-pll users are converted to use dvb-pll:

SAA7134_BOARD_MD7134                    Medion 7134
SAA7134_BOARD_ASUS_EUROPA2_HYBRID       Asus Europa2 OEM

The saa7134 functions philips_fmd1216_tuner_init(),
philips_fmd1216_tuner_sleep(), and philips_fmd1216_tuner_set_params() are
deleted and the dvb-pll versions are used.

This should result in equivalent sleep, init, and tuning sequences being sent
to the tuner.

For the cxusb driver, only one board is effected:

USB_PID_MEDION_MD95700          	Medion MD95700

This board used dvb_usb_tuner_init_i2c() and dvb_usb_tuner_set_params_i2c()
for init and tuning, respectively.  These functions are effectively the same
as the dvb-pll versions.  They call a tuner pass control function defined at
the dvb-usb level, but this does not matter, as this card does not have a
tuner pass control function (only the dib3000mb does).  This board will gain
the sleep sequence, while init and tuning should be unchanged.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:29 -03:00
Aapo Tahkola 4919c49278 V4L/DVB (5628): Add support for A-LINK DTU dvb-t adapter
Support for A-LINK DTU(m) is not included in this patch.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Acked-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:28 -03:00
Luca Olivetti e62a42090c V4L/DVB (5626): Marked af9005 driver as experimental and fix dependencies
Marked af9005 driver as experimental and add dependency for qt1010;
Added a dependency on qt1010 in Kconfig;
Corrected the experimental gain  reduction of the mt2060 in case of
strong signal (though it is code included in #ifdef 0).

Signed-off-by: Luca Olivetti <luca@ventoso.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:27 -03:00
Luca Olivetti af4e067e1d V4L/DVB (5625): Add support for the AF9005 demodulator from Afatech
Signed-off-by: Luca Olivetti <luca@ventoso.org>
Signed-off-by: Manu Abraham <abraham.manu@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:26 -03:00
Michael Krufky 79d3a8bede V4L/DVB (5652): Dibusb-mb: use dvb_attach for dib3000mb_attach
convert calls to dib3000mb_attach to use dvb_attach

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:26 -03:00
Michael Krufky fbfee8684f V4L/DVB (5651): Dibusb-mb: convert pll handling to properly use dvb-pll
moved tda665x pll_init into dvb_pll_desc dvb_pll_tda665x.initdata
convert handling of tda665x and tua6010xs to properly use dvb-pll

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:25 -03:00
Michael Krufky 9bc7c04852 V4L/DVB (5650): Umt-010: trivial whitespace cleanup
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:24 -03:00
Michael Krufky a3497135d8 V4L/DVB (5649): Umt-010: convert tua6034 handling to properly use dvb-pll
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:23 -03:00
Michael Krufky 8906939252 V4L/DVB (5648): Dvb/frontends: remove unnecessary #include's of "dvb-pll.h"
These sources do not need to #include "dvb-pll.h"

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:22 -03:00
Tony Wan 480f75acbc V4L/DVB (5647): Saa7134: enable ir-remote for 10moons TM300
Using Encore's key codes, we needn't add any additional key table.

Signed-off-by: Tony Wan <wankai@sjtu.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:21 -03:00
Tony Wan aaccb82bdb V4L/DVB (5646): V4l: saa7134: add support for 10moons TM300 card
Support the 10moons TM300 TV card (so called TV Master 3), which is a
10moons saa7130 based board.  Here not include features for the
IR-remote.
It has been tested using TVTIME.  The card was auto-detected and all the
input sources worked correct with sound.

Signed-off-by: Tony Wan <wankai@sjtu.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:20 -03:00
Thierry MERLE c5f48367fe 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>
2007-07-18 14:23:20 -03:00
Thierry MERLE ea1f83cee9 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>
2007-07-18 14:23:19 -03:00
David Warman 8c7189d193 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>
2007-07-18 14:23:17 -03:00
David Warman 9fe01e5c29 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>
2007-07-18 14:23:17 -03:00
Michael Krufky 9b98fd28b4 V4L/DVB (5635): Budget-av: convert philips sd1878 / tda8261 to use dvb-pll
removed philips_sd1878_tda8261_tuner_set_params, using dvb_pll_attach, instead.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:16 -03:00
Michael Krufky 8511df9ec2 V4L/DVB (5634): Saa7134-dvb: convert philips td1316 handling to use dvb-pll
removed mt352_aver777_tuner_calc_regs, using dvb_pll_attach, instead.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:15 -03:00
Michael Krufky 4abe9f9d94 V4L/DVB (5633): Tuv1236d: move rf input switching code into dvb-pll
This patch removes duplicate code from cx88-dvb and saa7134-dvb that handles
rf input switching for the TUV1236d tuner.

The functionality is added to dvb-pll, where all the other code that 
handles the TUV1236d is kept.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:14 -03:00
Michael Krufky 77d6750470 V4L/DVB (5632): Dvb-pll: pass dvb_frontend_parameters to generic set() function
Rename dvb_pll_desc.setbw() to set(), and accept struct dvb_frontend_parameters
instead of passing both freq and bandwidth, so that this may be used as a
generic function.

In order to do this, dvb_pll_configure must also be altered in the same manner,
to take struct dvb_frontend_parameters instead of freq and bandwidth.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:12 -03:00
Simon Arlott 900858ecb3 V4L/DVB (5631): Dvb-core: Add level fixes to printk()s, plus spelling/grammer
All the printks had missing level prefixes so I've fixed these too.
Also fixed some grammer errors.

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:12 -03:00
Trent Piepho ecf854df72 V4L/DVB (5629): Cx88: VP3054 support can't be a module when cx88 is compiled in
If cx88 support is compiled into the kernel while vp3054 is left as a module,
the kernel will fail to link.  Adjust the existing "#if" code in cx88 so
that it won't consider vp3054 to be supported in this case.

It might make sense to move vp3054 selection into the "customisation" menu
instead of a cx88 sub-option (though this is a cx88 feature, there is no extra
chip involved).

It might also make sense to use dvb_attach() to load vp3054 support.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:11 -03:00
Mauro Carvalho Chehab 8573a9e6a8 V4L/DVB (5563a): Add experimental support for tea5761 tuner
This driver were made based on tea5761 specs.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-18 14:23:11 -03:00
Rafael J. Wysocki 8314418629 Freezer: make kernel threads nonfreezable by default
Currently, the freezer treats all tasks as freezable, except for the kernel
threads that explicitly set the PF_NOFREEZE flag for themselves.  This
approach is problematic, since it requires every kernel thread to either
set PF_NOFREEZE explicitly, or call try_to_freeze(), even if it doesn't
care for the freezing of tasks at all.

It seems better to only require the kernel threads that want to or need to
be frozen to use some freezer-related code and to remove any
freezer-related code from the other (nonfreezable) kernel threads, which is
done in this patch.

The patch causes all kernel threads to be nonfreezable by default (ie.  to
have PF_NOFREEZE set by default) and introduces the set_freezable()
function that should be called by the freezable kernel threads in order to
unset PF_NOFREEZE.  It also makes all of the currently freezable kernel
threads call set_freezable(), so it shouldn't cause any (intentional)
change of behaviour to appear.  Additionally, it updates documentation to
describe the freezing of tasks more accurately.

[akpm@linux-foundation.org: build fixes]
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Nigel Cunningham <nigel@nigel.suspend2.net>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Cc: Gautham R Shenoy <ego@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-17 10:23:02 -07:00
Auke Kok 44c10138fd PCI: Change all drivers to use pci_device->revision
Instead of all drivers reading pci config space to get the revision
ID, they can now use the pci_device->revision member.

This exposes some issues where drivers where reading a word or a dword
for the revision number, and adding useless error-handling around the
read. Some drivers even just read it for no purpose of all.

In devices where the revision ID is being copied over and used in what
appears to be the equivalent of hotpath, I have left the copy code
and the cached copy as not to influence the driver's performance.

Compile tested with make all{yes,mod}config on x86_64 and i386.

Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Acked-by: Dave Jones <davej@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-11 16:02:10 -07:00
Hartmut Birr 1fb4a17f6e V4L/DVB (5822): Fix the return value in ttpci_budget_init()
if the call to budget_register() fails in ttpci_budget_int(),
ttpci_budget_init() returns success. The attached patch will
fix this problem.

Signed-off-by: Hartmut Birr <e9hack@googlemail.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-03 15:11:21 -03:00
Oleg Nesterov 1e4597e8f0 V4L/DVB (5818): CinergyT2: fix flush_workqueue() vs work->func() deadlock
Spotted and tested by Thomas Sattler <tsattler@gmx.de>.

cinergyT2.c does cancel_delayed_work() + flush_scheduled_work() while
holding cinergyt2->sem. This leads to deadlock because work->func()
needs the same mutex to complete. Another bug is that this code in fact
can't reliably stop the re-arming delayed_work.

Convert this code to use cancel_rearming_delayed_work() and move it
out of ->sem. Another mutex, ->wq_sem, was added to protect against the
concurrent open/resume.

This patch is a horrible hack to fix the lockup which happens in practice.
As Dmitry Torokhov pointed out this driver has other problems and needs
further changes.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-03 15:11:19 -03:00
Jelle Foks f057131fb6 V4L/DVB (5816): Cx88-blackbird: fix vidioc_g_tuner never ending list of tuners
v4l-info and other programs would loop indefinitely while querying the
tuners for cx88-blackbird cards.

The cause was that vidioc_g_tuner didn't return an error value for
qctrl->id != 0, making the application think there is a never ending
list of tuners...

This patch adds the same index check as done in vidioc_g_tuner() in
cx88-video.

Signed-off-by: Jelle Foks <jelle@foks.8m.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-03 15:11:16 -03:00
Trent Piepho 333408f215 V4L/DVB (5808): Bttv: fix v4l1 breaking the driver
If one uses a V4L *one* application, such as vlc or mplayer's v4l driver, as
the first user after the driver is loaded, the driver wedges itself and will
never capture properly.  Even if one uses a V4L2 application later, it still
won't work.

If one uses a V4L *two* application first, such as tvtime or mplayer's v4l2
driver, then the driver will be ok.  One can then run a V4L1 application, and
it will work.

It turns out the problem is with norm changing and the crop support that was
added in 2.6.21.  The driver defaults to PAL, and keeps the last norm it was
set too across opens.  If one changes the norm via V4L1, the cropping
parameters are not reset like they should be, and they'll remain broken across
device opens.

This patch removes the direct setting of btv->tvnorm in the V4L1 ioctl
VIDIOCSCHAN handler.  The norm is set via the existing call to set_input(),
which calls set_tvnorm(), which will reset the cropping values now that it is
able to detect the norm change.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-07-03 15:11:14 -03:00
Jeff Mahoney 58e78475ec saa7134: fix thread shutdown handling
This patch changes the test for the thread pid from >= 0 to > 0.

When the saa8134 driver initialization fails after a certain point, it goes
through the complete shutdown process for the driver.  Part of shutting it
down includes tearing down the thread for tv audio.

The test for tearing down the thread tests for >= 0.  Since the dev
structure is kzalloc'd, the test will always be true if we haven't tried to
start the thread yet.  We end up waiting on pid 0 to complete, which will
never happen, so we lock up.

This bug was observed in Novell Bugzilla 284718, when request_irq() failed.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Acked-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-06-28 11:34:54 -07:00
Trent Piepho 59faba1b31 Fix Kconfig dependency problems wrt boolean menuconfigs
If one has a dependency chain (tristate)FOO depends on (bool)BAR depends on
(tristate)BAZ, build problems will result.  If BAZ=m, then BAR can be set
y, which allows FOO=y.  It's possible to have FOO=y && BAZ=m, which
wouldn't be allowed if FOO depended directly on BAZ.  In effect, the bool
promotes the tristate from m to y.

This ends up causing a problem with several menuconfigs that look like:

menuconfig BAR
	bool
	depends on BAZ [tristate]
if BAR
config FOO
	tristate
endif

The solution used here is to add the dependencies of BAR to the if
statement, so that items in the if block will gain a direct
non-bool-promoted dependency on BAZ.  This is how it would work if a menu
was used instead of an if block.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Acked-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: "David S. Miller" <davem@davemloft.net>
Acked-by: Jeff Garzik <jeff@garzik.org>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Cc: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-06-28 11:34:53 -07:00
Hans Verkuil c43850981b V4L/DVB (5751): Ivtv: fix ia64 printk format warnings.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:54:41 -03:00
Mauro Carvalho Chehab 72fb39ea58 V4L/DVB (5761): Fix broken b2c2 dependency on non x86 architectures
This patch moves flexcop-dma (currently used only by flexcop-pci) to
b2c2-flexcop-pci module, that is dependent on CONFIG_PCI, fixing the bug 
as reported by Geert Uytterhoeven <geert@linux-m68k.org>:

drivers/media/dvb/b2c2/flexcop-dma.c uses the PCI DMA API, but
DVB_B2C2_FLEXCOP doesn't depend on PCI, causing the following problem on
PCI-less systems:

| linux/drivers/media/dvb/b2c2/flexcop-dma.c:20: warning: implicit declaration of function 'pci_alloc_consistent'
| linux/drivers/media/dvb/b2c2/flexcop-dma.c:20: warning: implicit declaration of function 'pci_alloc_consistent'

Apparently this is the flexcop DMA core, which is used by both
DVB_B2C2_FLEXCOP_PCI and DVB_B2C2_FLEXCOP_USB.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:54:39 -03:00
Hans Verkuil f2100d82b8 V4L/DVB (5673): Fix audio stuttering for saa711x/ivtv when in radio mode.
Signed-off-by: Jose Alberto Reguero <jareguero@telefonica.net>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:19 -03:00
Hans Verkuil 987e00ba5c V4L/DVB (5732): Add ivtv CROPCAP support and fix ivtv S_CROP for video output.
The VIDIOC_CROPCAP ioctl was missing in ivtv.
The handling of output video cropping was wrong. This has now been fixed.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:15 -03:00
Hans Verkuil 1f137600ca V4L/DVB (5730): Remove unused V4L2_CAP_VIDEO_OUTPUT_POS
V4L2_CAP_VIDEO_OUTPUT_POS was initially introduced for 2.6.22 but never
actually used: remove it before the final 2.6.22 is made.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:14 -03:00
Thierry Merle fe818d1d9a 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>
2007-06-08 08:21:14 -03:00
Oliver Endriss c6604150ab V4L/DVB (5716): Tda10086,tda826x: fix tuning, STR/SNR values
Several people reported unreliable reception with the current driver.
Furthermore, STR and SNR values seem to be inverted.
This fix is based on a patch posted by Hartmut Hackman.
Thanks to Helmut Auer for testing and helping to optimize the patch.
tda826x:
- set baseband cut-off to 19 MHz
tda10086:
- change the parameters of the carrier recovery loop
- toggle register 0x02 between 0x35 (tuning) and 0x00 (locked)
- invert STR and SNR values

Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:13 -03:00
Hans Verkuil dc02d50a6d V4L/DVB (5675): Move big PIO accesses from the interrupt handler to a workhandler
Sliced VBI transfers use PIO instead of DMA. This was done inside the
interrupt handler, but since PIO accesses are very slow this meant that
a lot of time was spent inside the interrupt handler. All PIO copies are
now moved to a workqueue. This should fix various issues with missing time
ticks and remote key hits.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:13 -03:00
Andrew Morton ffeb9ec72e V4L/DVB (5699): Cinergyt2: fix file release handler
If this mutex_lock_interruptible() does fail due to signal_pending() then the
state of the driver will get trashed in interesting ways, because userspace
cannot and will not retry the close().

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:12 -03:00
Russell King 624fc7f52b V4L/DVB (5700): Saa7111: fix picture settings cache bug
If the SAA7111 device is powered down, and requires re-initialisation when
the V4L device is opened (as on the NetWinder), the SAA7111 driver gets
completely confused about the current settings.

The problem is centred around the way the driver keeps _two_ cached copies
of the current settings - one of the struct video_picture settings, and one
of the registers.

When the decoder is re-initailised, the cached register settings are
overwritten, as are the values in the hardware registers.  However, the
cached video_picture settings are not.

Resolve this by removing the useless and buggy second level of caching for
video_picture.  Instead, provide a function which updates register values
if and only if the value we are going to write to the register has changed.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:12 -03:00
Mauro Carvalho Chehab 05f85839a2 V4L/DVB (5702): Fix Kconfig items to avoid linkedition errors
The recent changes on Kconfig broke compilation when VIDEO_DEV is compiled
as module. On some cases, drivers like VIDEO_BUF are compiled with 'y' option
instead of 'm':

...

Thanks to: Toralf Forster <toralf.foerster@gmx.de> for pointing this issue.
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-06-08 08:21:12 -03:00
Jonathan Corbet edd75ede2d V4L/DVB (5691): Ov7670: reset clkrc in rgb565 mode
A bug in the ov7670 sensor causes it to introduce noise unless the CLKRC
register is rewritten *after* setting the image mode.  Naturally,
resetting CLKRC in this way will cause other modes to fail.  So
carefully poke the register only when indicated.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:16:29 -03:00
Jonathan Corbet 7acf90c70c V4L/DVB (5690): Cafe_ccic: Properly power down the sensor
The proper method for powering down the sensor on OLPC systems has
changed somewhat; in particular, the sensor must be powered down
completely (rather than simply told to power down) or the associated
"camera active" LED will stay on.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:16:27 -03:00
matthieu castet 82c01d3d5a V4L/DVB (5680): Tuner-simple.c fix suport for SECAM with FI1216MF
Allow to use SECAM-BG with the FI1216MF tuner.

The selection is done with the secam=B module argument.

The default behaviour should be the same as before.

Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:16:25 -03:00
Simon Arlott 4abdcf933f V4L/DVB (5630): Dvb-core: Handle failures to create devices
dvb-core is not started early enough when device drivers that use dvb are
compiled in so dvb_register_device fails (silently) since dvb_class is
NULL, this runs dvb_init using subsys_initcall instead of module_init.

dvb_register_device will now check the return value of class_device_create.

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:00:14 -03:00
Manu Abraham a6d7613226 V4L/DVB (5639a): Fix dst usage count
Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:00:14 -03:00
Hans Verkuil c74e83a863 V4L/DVB (5670): Adding new fields to v4l2_pix_format broke the ABI, reverted that change
Reverted the change to struct v4l2_pix_format. I completely missed that
this struct was used by existing ioctls so that changing it broke the ABI.
I will have to think of another way of setting the top/left coordinates
but for now this change is reverted to preserve compatibility.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:00:13 -03:00
Mauro Carvalho Chehab bf57ab7ae7 V4L/DVB (5640): Fix: em28xx shouldn't be selecting VIDEO_BUF
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:00:12 -03:00
Mauro Carvalho Chehab d460f857a5 V4L/DVB (5639): Fix Kconfig dependencies for ivtv
ivtv were wrongly marked as dependent of USB.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-22 16:00:12 -03:00
Al Viro 1b2bad2f04 em28xx and ivtv should depend on PCI
.. because video-buf.c requires PCI, and VIDEO_EM28XX selects it.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-15 18:56:37 -07:00
Linus Torvalds 57a44415be Merge branch 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb
* 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (44 commits)
  V4L/DVB (5571): V4l1-compat:  Make VIDIOCSPICT return errors in a useful way
  V4L/DVB (5624): Radio-maestro.c cleanup
  V4L/DVB (5623): Dsbr100.c Replace usb_dsbr100_do_ioctl to use video_ioctl2
  V4L/DVB (5622): Radio-zoltrix.c cleanup
  V4L/DVB (5621): Radio-cadet.c Replace cadet_do_ioctl to use video_ioctl2
  V4L/DVB (5619): Dvb-usb: fix typo
  V4L/DVB (5618): Cx88: Drop the generic i2c client from cx88-vp3054-i2c
  V4L/DVB (5617): V4L2: videodev, allow debugging
  V4L/DVB (5614): M920x: Disable second adapter on LifeView TV Walker Twin
  V4L/DVB (5613): M920x: loosen up 80-col limit
  V4L/DVB (5612): M920x: rename function prefixes from m9206_foo to m920x_foo
  V4L/DVB (5611): M920x: replace deb_rc with deb
  V4L/DVB (5610): M920x: remove duplicated code
  V4L/DVB (5609): M920x: group like functions together
  V4L/DVB (5608): M920x: various whitespace cleanups
  V4L/DVB (5607): M920x: Initial support for devices likely manufactured by Dposh
  V4L/DVB (5606): M920x: add "c-basic-offset: 8" to help emacs to enforce tabbing
  V4L/DVB (5605): M920x: Add support for LifeView TV Walker Twin
  V4L/DVB (5603): V4L: Prevent queueing queued buffers.
  V4L/DVB (5602): Enable DiSEqC in Starbox II (vp7021a)
  ...
2007-05-11 12:57:16 -07:00
Martin Schwidefsky e25df1205f [S390] Kconfig: menus with depends on HAS_IOMEM.
Add "depends on HAS_IOMEM" to a number of menus to make them
disappear for s390 which does not have I/O memory.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-05-10 15:46:07 +02:00
Trent Piepho bbe2486fe3 V4L/DVB (5571): V4l1-compat: Make VIDIOCSPICT return errors in a useful way
Among other things, VIDIOCSPICT sets the pixel format.  Some drivers
don't support all formats, e.g. cx88 doesn't support the planar formats.
The compat code that translates VIDIOCSPICT into V4L2 ioctls doesn't pass
on any errors, so a userspace program doesn't know if it has selected an
unsupported pixel format.

VIDIOCSPICT sets both the memory capture and overlay formats, and it's
possible that one will be set while the other will fail, e.g. cx88
doesn't even support overlay.  Also, trying to set the overlay format
will fail for non-root users.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:09 -03:00
Douglas Landgraf 9d3eb99b36 V4L/DVB (5624): Radio-maestro.c cleanup
Removed unnecessary semaphore.

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:09 -03:00
Douglas Landgraf 7002a4f350 V4L/DVB (5623): Dsbr100.c Replace usb_dsbr100_do_ioctl to use video_ioctl2
Convert dsbr100 to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:08 -03:00
Douglas Landgraf 2437c6d47c V4L/DVB (5622): Radio-zoltrix.c cleanup
Removed unnecessary .hardware member from struct zoltrix_radio
(video_device).

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:07 -03:00
Douglas Landgraf c1c4fd3eee V4L/DVB (5621): Radio-cadet.c Replace cadet_do_ioctl to use video_ioctl2
Convert radio-cadet to use video_ioctl2

Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:07 -03:00
Michael Krufky 09129f0d14 V4L/DVB (5619): Dvb-usb: fix typo
replace "streaming_crtl" with "streaming_ctrl"

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:06 -03:00
Jean Delvare ed69686a16 V4L/DVB (5618): Cx88: Drop the generic i2c client from cx88-vp3054-i2c
Drop the generic client declared in cx88-vp3054-i2c: it's not used
anywhere. This shrinks cx88-vp3054-i2c.o by 29% on x86_64. Unless it
was there for later use?

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:05 -03:00
Jiri Slaby 57e45b31c1 V4L/DVB (5617): V4L2: videodev, allow debugging
videodev, allow debugging
fix typo? in videodev.c to allow debugging

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:04 -03:00
Nick Andrew 14c4ffbe68 V4L/DVB (5614): M920x: Disable second adapter on LifeView TV Walker Twin
Disable second adapter on LifeView TV Walker Twin while it doesn't work 
properly.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Nick Andrew <nick@nick-andrew.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:04 -03:00
Aapo Tahkola 9ad4eef2f4 V4L/DVB (5613): M920x: loosen up 80-col limit
Do not follow 80-col limit where it would cause inconsistency.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:03 -03:00
Aapo Tahkola 4fd74a776f V4L/DVB (5612): M920x: rename function prefixes from m9206_foo to m920x_foo
Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:02 -03:00
Aapo Tahkola bf2b4f67a4 V4L/DVB (5611): M920x: replace deb_rc with deb
deb_rc is used by the dvb-usb core framework.  This patch replaces all
occurances of deb_rc with deb, in m920x.c, so that its clear that we're
not using dvb-usb's deb_rc.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:01 -03:00
Michael Krufky e7b419b692 V4L/DVB (5610): M920x: remove duplicated code
Some of the devices supported by the m920x driver have identical functions used
for tuner_attach and frontend_attach.  This patch consolidates the functions in
question, and updates the debug code to be generic for each.  This patch
decreases the size of the kernel.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:00 -03:00
Michael Krufky 5afb707120 V4L/DVB (5609): M920x: group like functions together
- Group the tuner configurations together.
- Group the demod configurations together.
- Group the device-specific initialization functions together.
- Group demod_attach functions together.
- Group tuner_attach functions together.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:13:00 -03:00
Michael Krufky d3911eaa0d V4L/DVB (5608): M920x: various whitespace cleanups
- 80-column cleanups
- spaces between operators
- tabbing style

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:59 -03:00
Aapo Tahkola f8e0bd5db4 V4L/DVB (5607): M920x: Initial support for devices likely manufactured by Dposh
These devices are sold by various companies and chains not involved in
hardware manufacturing business. This particular device owned by
winisch (from irc) had a sticker with text "TCM 234292" on it. This device
was never opened so it is possible that Dposh did not manufacture this
stick. However, the bundled software and their product line points into
that direction. Also thanks to Michael Krufky for spotting this hw
filtering problem and thus avoiding hair loss.
Hardware pid filters and the bundled remote controller are not currently
supported on this device.

Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:58 -03:00
Michael Krufky ce9c275034 V4L/DVB (5606): M920x: add "c-basic-offset: 8" to help emacs to enforce tabbing
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:58 -03:00
Nick Andrew aa50ec2b49 V4L/DVB (5605): M920x: Add support for LifeView TV Walker Twin
Add support for "LifeView TV Walker Twin" (USB IDs 10fd:0513, 10fd:0514)

Signed-off-by: Nick Andrew <nick@nick-andrew.net>
Signed-off-by: Aapo Tahkola <aet@rasterburn.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:57 -03:00
Sakari Ailus 36a63ee34b V4L/DVB (5603): V4L: Prevent queueing queued buffers.
videobuf_qbuf queues buffers to q->stream but does not properly check
the state of the buffer before queueing. It was possible to queue
buffers that already were in the queue.
Only buffers that are in states STATE_NEEDS_INIT and STATE_IDLE can be
queued.

Signed-off-by: Sakari Ailus <sakari.ailus@nokia.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:56 -03:00
Pat Erley 5ad5e4845b V4L/DVB (5602): Enable DiSEqC in Starbox II (vp7021a)
Uncomments code in vp702x-fe.c to enable DiSEqC in vp7021a

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Pat Erley <pat@erley.org>
Signed-off-by: Patrick Boettcher <pb@linuxtv.org>
2007-05-09 10:12:55 -03:00
Mauro Carvalho Chehab 9a95735dde V4L/DVB (5601): Create a menu for DAB
DABUSB driver were a little lost at Multimedia core menu.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:54 -03:00
Mauro Carvalho Chehab 523b78d1d2 V4L/DVB (5600): Allow compiling just DVB CORE
Allow compiling just DVB CORE without needing to compile the drivers

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:49 -03:00
Jan Engelhardt 6b6bcb16c6 V4L/DVB (5599): Use menuconfig objects II - DVB
Change Kconfig objects from "menu, config" into "menuconfig" so
that the user can disable the whole feature without having to
enter the menu first.
Also remove one indirection (CONFIG_DVB) that does not seem to
be really used inside the kernel.

Signed-off-by: Jan Engelhardt <jengelh@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:48 -03:00
Oliver Endriss 910a7b6835 V4L/DVB (5593): Budget-ci: Fix tuning for TDM 1316 (160..200 MHz)
Revert changeset
  http://linuxtv.org/hg/v4l-dvb?cmd=changeset;node=e7c424bbf9aa;style=gitweb

Petri Helin found that this changeset broke tuning:

'Well, after going through the changes that might have had effect on
tuning, I found out the one which had caused this problem. I do not know
the actual reason behind the change, but the changelog says that it
was meant to "Fix TD1316 tuner for DVBC". But at least in my case it
seams to have broken the tuner instead.'

Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Thanks-to: Petri Helin <phelin@googlemail.com>
Acked-by: e9hack <e9hack@googlemail.com>
Acked-by: Thomas Kaiser <linux-dvb@kaiser-linux.li>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:42 -03:00
Jon Burgess 87c3019d7b V4L/DVB (5592): DMA: Correctly free resources on error, sync PCI streamed data
I added saa7146_vmalloc_destroy_pgtable() which frees the resources
allocated by saa7146_vmalloc_build_pgtable() and updated the callers in
budget-core.c and av7110.c. I have also been through the updated
functions and updated the error paths to ensure they free all allocated
resources on error.
I also realised that there are other callers to saa7146_pgtable_free()
which did not have any sg DMA mapped so it seems wrong to add the
pci_unmap_sg() into that function. Instead I created
saa7146_vmalloc_destroy_pgtable() to do this.
Also included in this patch are the previous fixes for pci_unmap_sg()
and syncing the PCI streamed data to work with a SWIOTLB and match the
requirements documented in DMA-API.txt.

Signed-off-by: Jon Burgess <jburgess777@googlemail.com>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:42 -03:00
Adrian Bunk 32a1db4248 V4L/DVB (5591): Saa7146: proper prototype for saa7146_video_do_ioctl()
This patch adds a proper prototype for saa7146_video_do_ioctl() in
include/media/saa7146_vv.h.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:41 -03:00
Mauro Carvalho Chehab ff01652cf8 V4L/DVB (5587): Add help for RADIO_ADAPTERS and VIDEO_CAPTURE_DRIVERS
Add a small help for those two new Kconfig vars.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:40 -03:00
Jan Engelhardt c5da5afb9d 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>
2007-05-09 10:12:39 -03:00
Luca Risolia 480b55c26e V4L/DVB (5585): SN9C1xx driver updates
* Default color improvements to the OV7660
@ Fix sn9c102_write_reg()
@ Fix sn9c102_i2c_try_raw_read()
@ Fix MI-0343
+ Add support for pair MI0360+SN9C120
+ Add more USB ids

Signed-off-by: Luca Risolia <luca.risolia@studio.unibo.it>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:38 -03:00
Robert P. J. Day b3785596e3 V4L/DVB (5583): VIDEO4LINUX-2: Replace MINOR() with a call to iminor().
Replace the call to MINOR() with a call to the inline iminor()
routine.

Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:38 -03:00
James T Klaas 53958b35e4 V4L/DVB (5582): Added support for Sabrent TV-PCB05 card.
Maintainer's notice: I needed to re-number the board, since the board
number conflicted with a patch committed previously.

Signed-off-by: James T Klaas <jklaas@appalachian.dyndns.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:37 -03:00
Simon Farnsworth b39423a95c V4L/DVB (5580): Add support for three cards to saa7134 driver
Add support for the "Elitegroup ECS TVP3XP FM1246", the "KWorld DVB-T
210", and the Animation Technologies LR214 Rev F onwards (SAA7131) to
the saa7134 driver.
Also rename the LR214WF to the LR214 Rev E or ealier (SAA7135), to match
what we've seen on boards in the field.
Changed the comment on the Lifeview cards to indicate Rev E and earlier
versus Rev F and later, together with a chip indicator, following
feedback from Peter Missel <peter.missel@onlinehome.de>.

Signed-off-by: Simon Farnsworth <simon.farnsworth@onelan.co.uk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:36 -03:00
holger@muscate-magnussen.de 4d84517001 V4L/DVB (5578): Workaround for bad hardare/firmware on some pluto2 devices
pluto2_driver: Workaround for pluto2 card reporting wrong number of
received packets and flooding system with interrupts.

This patch constitutes a workaround for a hardware/firmware problem of the
pluto2-based card (e.g., Satelco EasyWatch).

It can happen in rare cases that the card gets into a mode where it
always reports back a number of received packets (nbpackets) which is
larger than the maximum permissible number of packets (TS_DMA_PACKETS).
The workaround that is already in the driver in function pluto_dma_end
reports back zero received packets. In spite of the (in reality) zero
received packets the card continues to generate interrupts at a very
high rate, which can effectively stall the system.

The patch resets the TS logic, which puts the card back into normal
operations.

Signed-off-by: Holger Magnussen <holger@muscate-magnussen.de>
Signed-off-by: Andreas Oberritter <obi@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:35 -03:00
Servaas Vandenberghe ba70d59bb9 V4L/DVB (5576): Improve / fix support for PAL-60 in cx25840
This causes the cx25840 module to treat V4L2_STD_PAL_60 similar to
other 60Hz timings, and it fixes a wrongly-named variable (timings are
independant of color system).

Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:34 -03:00
Mike Isely 5c808e6417 V4L/DVB (5575): Pvrusb2: Implement ability to disable IR receiver
Anyone using multiple PVR USB2 devices really only want one of them
acting as the actual IR receiver.  

Implemented here is a new per-instance module option (ir_mode) which is 
a flag to enable the IR receiver.  The default is enabled.  

IR reception is disabled by blocking access to the IR receiver chip in 
the device.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:34 -03:00
Mike Isely db71b7df76 V4L/DVB (5574): Pvrusb2: Improve handling of PAL-60 video standard
This patch originated with Servaas Vandenberghe <vdb128@picaros.org>
and has been further developed a bit (to preserve saa7115 behavior).

These changes allow for correct operation of PAL-60 video (Servaas
tested this against a PAL-B/G tuner with the video standard overridden
as a module option).

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:33 -03:00
Tejun Heo 4f393828d1 V4L/DVB (5573): Pvrusb2: kill unnecessary attribute->owner
sysfs is now completely out of driver/module lifetime game.

After deletion, a sysfs node doesn't access anything outside sysfs 
proper, so there's no reason to hold onto the attribute owners.

Note that often the wrong modules were accounted for as owners leading 
to accessing removed modules. 

This patch kills now unnecessary attribute->owner.  

Note that with this change, userland holding a sysfs node does not 
prevent the backing module from being unloaded. 

For more info regarding lifetime rule cleanup, please read the following 
message:
	http://article.gmane.org/gmane.linux.kernel/510293

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:32 -03:00
Matthias Kaehlcke 8df0c87cc3 V4L/DVB (5572): Pvrusb2: use mutex instead of semaphore
The pvrusb2 driver use a semaphore as mutex. use the mutex API instead
of the (binary) semaphore.

Signed-off-by: Matthias Kaehlcke <matthias.kaehlcke@gmail.com>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:31 -03:00
Trent Piepho 5f12491c36 V4L/DVB (5570): V4l1-compat: misc fixes for pixelformat function
Mark the palette2pixelformat lookup table as const

pixelformat is unsigned, adjust the palette2pixelformat table and
pixelformat_to_palette()

palette_to_pixelformat() is a pure function

pixelformat_to_palette() is a const function

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:30 -03:00
Mauro Carvalho Chehab 452c0fb46b V4L/DVB (5569): Fix: v4l1_compat should be called only if V4L1_COMPAT
Added also some explanations about V4L1 handling

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:29 -03:00
Sam Revitch 1088b13735 V4L/DVB (5568): VIDIOCGMBUF handling in video_ioctl2()
Correct handling of VIDIOCGMBUF in video_ioctl2().

Signed-off-by: Sam Revitch <samr7@cs.washington.edu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:29 -03:00
Adrian Bunk 9df2ead585 V4L/DVB (5567): Cx88-mpeg.c: make 2 functions static
This patch makes two needlessly global functions static.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:29 -03:00
Thomas Gleixner b71ed5cfe6 V4L/DVB (5566): MEDIA: Spinlock initializer cleanup
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:28 -03:00
Alexey Dobriyan 45e95980f2 V4L/DVB (5565): Cx88: fix compilation on alpha
error: 'DMA_32BIT_MASK' undeclared

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-05-09 10:12:27 -03:00
Matt LaPlante a982ac06b0 misc doc and kconfig typos
Fix various typos in kernel docs and Kconfigs, 2.6.21-rc4.

Signed-off-by: Matt LaPlante <kernel1@cyberdogtech.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
2007-05-09 08:58:15 +02:00
Michael Opdenacker 59c51591a0 Fix occurrences of "the the "
Signed-off-by: Michael Opdenacker <michael@free-electrons.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
2007-05-09 08:57:56 +02:00
Robert P. J. Day beb7dd86a1 Fix misspellings collected by members of KJ list.
Fix the misspellings of "propogate", "writting" and (oh, the shame
:-) "kenrel" in the source tree.

Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
2007-05-09 07:14:03 +02:00
Jean Delvare b3561ea946 Clean up mutex_trylock noise
Ingo Molnar's semaphore to mutex conversions left some noise on a few
trylock calls. Clean it up.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-08 11:15:13 -07:00
Randy Dunlap e63340ae6b 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>
2007-05-08 11:15:07 -07:00
Andrew Morton c24228daa1 cx88-video build fix
alpha:

drivers/media/video/cx88/cx88-video.c: In function 'cx8800_initdev':
drivers/media/video/cx88/cx88-video.c:1782: error: 'DMA_32BIT_MASK' undeclared (first use in this function)
drivers/media/video/cx88/cx88-video.c:1782: error: (Each undeclared identifier is reported only once
drivers/media/video/cx88/cx88-video.c:1782: error: for each function it appears in.)

Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-07 12:13:04 -07:00
Linus Torvalds 89661adaae Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6: (59 commits)
  PCI: Free resource files in error path of pci_create_sysfs_dev_files()
  pci-quirks: disable MSI on RS400-200 and RS480
  PCI hotplug: Use menuconfig objects
  PCI: ZT5550 CPCI Hotplug driver fix
  PCI: rpaphp: Remove semaphores
  PCI: rpaphp: Ensure more pcibios_add/pcibios_remove symmetry
  PCI: rpaphp: Use pcibios_remove_pci_devices() symmetrically
  PCI: rpaphp: Document is_php_dn()
  PCI: rpaphp: Document find_php_slot()
  PCI: rpaphp: Rename rpaphp_register_pci_slot() to rpaphp_enable_slot()
  PCI: rpaphp: refactor tail call to rpaphp_register_slot()
  PCI: rpaphp: remove rpaphp_set_attention_status()
  PCI: rpaphp: remove print_slot_pci_funcs()
  PCI: rpaphp: Remove setup_pci_slot()
  PCI: rpaphp: remove a call that does nothing but a pointer lookup
  PCI: rpaphp: Remove another wrappered function
  PCI: rpaphp: Remve another call that is a wrapper
  PCI: rpaphp: remove a function that does nothing but wrap debug printks
  PCI: rpaphp: Remove un-needed goto
  PCI: rpaphp: Fix a memleak; slot->location string was never freed
  ...
2007-05-04 18:04:29 -07:00
Jean Delvare 6473d160b4 PCI: Cleanup the includes of <linux/pci.h>
I noticed that many source files include <linux/pci.h> while they do
not appear to need it. Here is an attempt to clean it all up.

In order to find all possibly affected files, I searched for all
files including <linux/pci.h> but without any other occurence of "pci"
or "PCI". I removed the include statement from all of these, then I
compiled an allmodconfig kernel on both i386 and x86_64 and fixed the
false positives manually.

My tests covered 66% of the affected files, so there could be false
positives remaining. Untested files are:

arch/alpha/kernel/err_common.c
arch/alpha/kernel/err_ev6.c
arch/alpha/kernel/err_ev7.c
arch/ia64/sn/kernel/huberror.c
arch/ia64/sn/kernel/xpnet.c
arch/m68knommu/kernel/dma.c
arch/mips/lib/iomap.c
arch/powerpc/platforms/pseries/ras.c
arch/ppc/8260_io/enet.c
arch/ppc/8260_io/fcc_enet.c
arch/ppc/8xx_io/enet.c
arch/ppc/syslib/ppc4xx_sgdma.c
arch/sh64/mach-cayman/iomap.c
arch/xtensa/kernel/xtensa_ksyms.c
arch/xtensa/platform-iss/setup.c
drivers/i2c/busses/i2c-at91.c
drivers/i2c/busses/i2c-mpc.c
drivers/media/video/saa711x.c
drivers/misc/hdpuftrs/hdpu_cpustate.c
drivers/misc/hdpuftrs/hdpu_nexus.c
drivers/net/au1000_eth.c
drivers/net/fec_8xx/fec_main.c
drivers/net/fec_8xx/fec_mii.c
drivers/net/fs_enet/fs_enet-main.c
drivers/net/fs_enet/mac-fcc.c
drivers/net/fs_enet/mac-fec.c
drivers/net/fs_enet/mac-scc.c
drivers/net/fs_enet/mii-bitbang.c
drivers/net/fs_enet/mii-fec.c
drivers/net/ibm_emac/ibm_emac_core.c
drivers/net/lasi_82596.c
drivers/parisc/hppb.c
drivers/sbus/sbus.c
drivers/video/g364fb.c
drivers/video/platinumfb.c
drivers/video/stifb.c
drivers/video/valkyriefb.c
include/asm-arm/arch-ixp4xx/dma.h
sound/oss/au1550_ac97.c

I would welcome test reports for these files. I am fine with removing
the untested files from the patch if the general opinion is that these
changes aren't safe. The tested part would still be nice to have.

Note that this patch depends on another header fixup patch I submitted
to LKML yesterday:
  [PATCH] scatterlist.h needs types.h
  http://lkml.org/lkml/2007/3/01/141

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Badari Pulavarty <pbadari@us.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-05-02 19:02:35 -07:00
Jean Delvare 7c59b6615f 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>
2007-05-01 23:26:29 +02:00
David Brownell 2096b956d2 i2c: Shrink struct i2c_client
This shrinks the size of "struct i2c_client" by 40 bytes:

 - Substantially shrinks the string used to identify the chip type
 - The "flags" don't need to be so big
 - Removes some internal padding

It also adds kerneldoc for that struct, explaining how "name" is really a
chip type identifier; it's otherwise potentially confusing.

Because the I2C_NAME_SIZE symbol was abused for both i2c_client.name
and for i2c_adapter.name, this needed to affect i2c_adapter too.  The
adapters which used that symbol now use the more-obviously-correct
idiom of taking the size of that field.

JD: Shorten i2c_adapter.name from 50 to 48 bytes while we're here, to
avoid wasting space in padding.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-05-01 23:26:28 +02:00
Linus Torvalds 24a77daf3d Merge branch 'for-2.6.22' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'for-2.6.22' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (255 commits)
  [POWERPC] Remove dev_dbg redefinition in drivers/ps3/vuart.c
  [POWERPC] remove kernel module option for booke wdt
  [POWERPC] Avoid putting cpu node twice
  [POWERPC] Spinlock initializer cleanup
  [POWERPC] ppc4xx_sgdma needs dma-mapping.h
  [POWERPC] arch/powerpc/sysdev/timer.c build fix
  [POWERPC] get_property cleanups
  [POWERPC] Remove the unused HTDMSOUND driver
  [POWERPC] cell: cbe_cpufreq cleanup and crash fix
  [POWERPC] Declare enable_kernel_spe in a header
  [POWERPC] Add dt_xlate_addr() to bootwrapper
  [POWERPC] bootwrapper: CONFIG_ -> CONFIG_DEVICE_TREE
  [POWERPC] Don't define a custom bd_t for Xilixn Virtex based boards.
  [POWERPC] Add sane defaults for Xilinx EDK generated xparameters files
  [POWERPC] Add uartlite boot console driver for the zImage wrapper
  [POWERPC] Stop using ppc_sys for Xilinx Virtex boards
  [POWERPC] New registration for common Xilinx Virtex ppc405 platform devices
  [POWERPC] Merge common virtex header files
  [POWERPC] Rework Kconfig dependancies for Xilinx Virtex ppc405 platform
  [POWERPC] Clean up cpufreq Kconfig dependencies
  ...
2007-04-30 08:10:12 -07:00
Paul Mackerras 49e1900d4c Merge branch 'linux-2.6' into for-2.6.22 2007-04-30 12:38:01 +10:00
Linus Torvalds 6b06d2cc6d Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (105 commits)
  sonypi: use mutex instead of semaphore
  sony-laptop: remove user visible camera controls as platform attributes
  meye: make meye use sony-laptop instead of sonypi
  sony-laptop: add a meye-usable include file for camera ops
  sony-laptop: complete the motion eye camera support in sony-laptop
  sonypi: try to detect if sony-laptop has already taken one of the known ioports
  sonypi: suggest sonypi users to try sony-laptop instead
  sony-laptop: add edge modem support (also called WWAN)
  sony-laptop: add locking on accesses to the ioport and global vars
  sony-laptop: add camera enable/disable parameter, better handle possible infinite loop
  thinkpad-acpi: make drivers/misc/thinkpad_acpi:fan_mutex static
  ACPI: thinkpad-acpi: add sysfs support to wan and bluetooth subdrivers
  ACPI: thinkpad-acpi: add sysfs support to hotkey subdriver
  ACPI: thinkpad-acpi: improve dock subdriver initialization
  ACPI: thinkpad-acpi: improve debugging for acpi helpers
  ACPI: thinkpad-acpi: improve fan control documentation
  ACPI: thinkpad-acpi: map ENXIO to EINVAL for fan sysfs
  ACPI: thinkpad-acpi: fix a fan watchdog invocation
  ACPI: thinkpad-acpi: do not arm fan watchdog if it would not work
  ACPI: thinkpad-acpi: add a fan-control feature master toggle
  ...
2007-04-29 10:47:25 -07:00
Len Brown cfaae3ee4a Pull sony into release branch 2007-04-28 23:09:57 -04:00
malattia@linux.it cbefb762b6 meye: make meye use sony-laptop instead of sonypi
Change sonypi_camera_command() calls to sony_pic_camera_command() and use
the renamed macros.

Signed-off-by: Mattia Dongili <malattia@linux.it>
Signed-off-by: Len Brown <len.brown@intel.com>
2007-04-28 22:06:02 -04:00
Douglas Landgraf d455cf5d0d V4L/DVB (5563): Radio-maestro.c Replace radio_ioctl to use video_ioctl2
Convert radio-maestro to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:46:01 -03:00
Douglas Landgraf 6f66446c54 V4L/DVB (5562): Radio-gemtek-pci.c Replace gemtek_pci_ioctl to use video_ioctl2
Convert radio-gemtek-pci to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:46:00 -03:00
Hans Verkuil 018ba85bf6 V4L/DVB (5560): Ivtv: fix incorrect bitwise-and for command flags.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:59 -03:00
Marco Gittler 86534e5e8e V4L/DVB (5558): Opera: use 7-bit i2c addresses
- the tuner i2c addr now without define (as wanted).
- now 7 bit addr are used (the power_ctrl fkt ist ok so,
  because this is a raw write)
- the addr >> 1 , addr << 1 is ok so, i think beause the
  read write is now taken from the last bit.
- now i have no datasheet for the device, all taken from usb-logs

Signed-off-by: Marco Gittler <g.marco@freenet.de>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:59 -03:00
Trent Piepho 12df2f54e5 V4L/DVB (5557): Cafe_ccic: check return value of pci_enable_device
Remove warnings

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Acked-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:58 -03:00
Douglas Landgraf e9bb9c6439 V4L/DVB (5556): Radio-gemtek.c Replace gemtek_ioctl to use video_ioctl2
Convert radio-gemtek to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:57 -03:00
Douglas Landgraf 385e8d8fc6 V4L/DVB (5555): Radio-aimslab.c Replace rt_ioctl to use video_ioctl2
Convert radio-aimslab to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:56 -03:00
Mauro Carvalho Chehab 2aa2342f2b V4L/DVB (5554): Fix: vidioc_g_parm were not zeroing the memory
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:56 -03:00
Douglas Landgraf 3f6892aca5 V4L/DVB (5553): Replace typhoon_do_ioctl to use video_ioctl2
Convert radio-typhoon to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:55 -03:00
Alan Cox 74ea1c7a7e V4L/DVB (5552): Plan-b: Switch to refcounting PCI API
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:54 -03:00
Alan Cox 8ca966d7fd V4L/DVB (5551): Plan-b: header change
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:53 -03:00
Douglas Landgraf c123b86771 V4L/DVB (5550): Radio-sf16fmi.c Replace fmi_do_ioctl to use video_ioctl2
Convert radio-sf16fmi to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:53 -03:00
Douglas Landgraf 34ab962db8 V4L/DVB (5549): Radio-sf16fmr2.c Replace fmr2_do_ioctl to use video_ioctl2
Convert radio-sf16fmr2 to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:52 -03:00
Luc Saillard 288bb0e790 V4L/DVB (5548): Fix v4l2 buffer to the length
Set the length of the v4l2 buffer to the length of the mapped memory.

This should fix the problem with amsn.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:51 -03:00
Luc Saillard 9ee6d78cd4 V4L/DVB (5547): Add ENUM_FRAMESIZES and ENUM_FRAMEINTERVALS ioctls
This patch add support for the VIDIOC_ENUM_FRAMESIZES and
VIDIOC_ENUM_FRAMEINTERVALS ioctl.
* check if the maximum native framesize for raw mode is correct
* raw mode framerates for all three chipset types

Signed-off-by: Gregor Jasny <gjasny@web.de>
Signed-off-by: Luc Saillard <luc@saillard.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:50 -03:00
Douglas Landgraf 1de6923811 V4L/DVB (5546): Radio-terratec.c Replace tt_do_ioctl to use video_ioctl2
Convert radio-terratec to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:49 -03:00
Hartmut Birr 2970c49270 V4L/DVB (5545): Saa7146: Release capture buffers on device close
If the video device (saa7146 on a FF card) was open for capturing,
the close call didn't release the capture buffers.

Signed-off-by: Hartmut Birr <e9hack@gmail.com>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:48 -03:00
Hartmut Birr dc120b0734 V4L/DVB (5544): Budget-av: Make inversion setting configurable, add KNC ONE V1.0 card
Make the inversion setting configurable. The KNC ONE V1.0 uses
non inverted setting for the inversion and add the KNC ONE V1.0 card.

Signed-off-by: Hartmut Birr <e9hack@googlemail.com>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:48 -03:00
Hartmut Birr aa323ac89c V4L/DVB (5543): Tda10023: Add support for frontend TDA10023
Add support for the frontend TDA10023 and add cards that need the
tda10023.

Signed-off-by: Hartmut Birr <e9hack@googlemail.com>
Signed-off-by: Georg Acher <acher@in.tum.de>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:47 -03:00
Hartmut Birr fd9c66e269 V4L/DVB (5542): Budget-av: Remove polarity switching of the clock for DVB-C
Remove the polarity switching of the clock for the DVB-C cards in
budget-av.c. This hack is no longer necessary because the saa7146 can
do the job to remove the additional FEC bytes from the TS.

Signed-off-by: Hartmut Birr <e9hack@googlemail.com>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:46 -03:00
Douglas Landgraf a1314b1ab6 V4L/DVB (5541): Radio-zoltrix.c Replace zol_do_ioctl to use video_ioctl2
Convert radio-zoltrix to use video_ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:45 -03:00
Douglas Landgraf c5f822bf60 V4L/DVB (5540): Radio-trust.c Replace tr_do_ioctl to use video_ioctl2
Convert radio-trust to use video ioctl2

Signed-off-by:  Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:45 -03:00
Douglas Landgraf 8b811cf0c6 V4L/DVB (5539): Radio-rtrack2.c Added VIDIOC_[GS]_AUDIO and VIDIOC_[S|G]_INPUT
Implements VIDIOC_[GS]_AUDIO and VIDIOC_[S|G]_INPUT on radio-rtrack2

Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:44 -03:00
Thierry MERLE ec709bb801 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>
2007-04-27 15:45:43 -03:00
Douglas Landgraf 25f30389dd V4L/DVB (5534): Radio-rtrack2.c Replace rt_ioctl to use video_ioctl2
Convert radio-rtrack2 to use video_ioctl2

Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:42 -03:00
Marco Gittler 941491f3a5 V4L/DVB (5532): Add support for Opera S1- DVB-USB
This patch adds support for DVB-Opera S1 USB 2.0 BOX.

Signed-off-by: Marco Gittler <g.marco@freenet.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:42 -03:00
Thierry MERLE 6284feafcf 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>
2007-04-27 15:45:41 -03:00
Thierry MERLE bf8b20e190 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>
2007-04-27 15:45:41 -03:00
vignesh.babu@wipro.com c42cabefce V4L/DVB (5526): Cx88-alsa.c: Use kzalloc
Replacing kmalloc/memset combination with kzalloc.

Signed-off-by: vignesh babu <vignesh.babu@wipro.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:40 -03:00
Trent Piepho 3153bd91bf 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>
2007-04-27 15:45:40 -03:00
Akinobu Mita 66ab6e023e V4L/DVB (5513): Bt878: prevent probing wrong card entry
I got strange message when I did modprobe bt878:
bt878_probe: card id=[0x0],[ <NULL> ] has DVB functions.
The card_list array is terminated by sentinel entry.
But this list is traversed by:
for (i = 0, dvb_cards = card_list; i < ARRAY_SIZE(card_list);
     i++, dvb_cards++) {
...
}
in bt878_probe().
So this loop checks dummy sentinel entry, too.
This patch removes unnecessary sentinel entry.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:39 -03:00
Thierry MERLE f2c340583c 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>
2007-04-27 15:45:39 -03:00
Thierry MERLE 672d013bed 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>
2007-04-27 15:45:38 -03:00
Thierry MERLE 1ff16c2091 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>
2007-04-27 15:45:37 -03:00
Mauro Carvalho Chehab d3df9c4fa1 V4L/DVB (5521): Usb_get_dev were called twice. Removing the extra call.
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:37 -03:00
Ville-Pekka Vainio 28aedb8fd9 V4L/DVB (5520): Add support for the extra keys in the black Technotrend 1500 IR
It has come to my knowledge that the Technotrend 1500 DVB cards have 
been sold bundled with at least two different kinds of remotes, a grey 
one and a black one. 
This patch adds support for the extra keys in the black remote to 
ir-keymaps.c.

Signed-off-by: Ville-Pekka Vainio <vpivaini@cs.helsinki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:35 -03:00
Mauro Carvalho Chehab f8a389db50 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>
2007-04-27 15:45:35 -03:00
Trent Piepho c682b3a7fb 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>
2007-04-27 15:45:34 -03:00
Mauro Carvalho Chehab f7ca6256bc 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>
2007-04-27 15:45:33 -03:00
Mauro Carvalho Chehab 659ae56dcd 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>
2007-04-27 15:45:32 -03:00
Markus Rechberger 2c4d336468 V4L/DVB (5512): Fix 3/3 for bug 7819: fixed hotplugging for dvbnet
fixed hotplugging for dvbnet

Signed-off-by: Michal CIJOML Semler <cijoml@volny.cz>
Signed-off-by: Markus Rechberger <markus.rechberger@amd.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:32 -03:00
Markus Rechberger 57861b432b V4L/DVB (5511): Fix 2/3 for bug 7819: demux and dvr
fixing hotplug issue for demux[n] and dvr[n]

Signed-off-by: Michal CIJOML Semler <cijoml@volny.cz>
Signed-off-by: Markus Rechberger <markus.rechberger@amd.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:31 -03:00
Markus Rechberger ca5be9cd05 V4L/DVB (5510): Fix 1/3 for bug 7819: fixed frontend hotplug issue
fixed frontend hotplug issue

Signed-off-by: Michal CIJOML Semler <cijoml@volny.cz>
Signed-off-by: Markus Rechberger <markus.rechberger@amd.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:30 -03:00
Mike Isely 31a1854706 V4L/DVB (5507): Pvrusb2: Gather USB bus address info and report it
The V4L2 API requires a unique bus_info string returned as part of the
v4l2_capability structure.  These changes gather up the USB address
information, from the underlying device, into a string and report that
out through v4l2 and via sysfs (for completeness).

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:30 -03:00
Hendrik Borghorst 4f210e0722 V4L/DVB (5505): Fix Kernel Bugzilla #8301: spinlock fix for flexcop-pci
If you modprobe the b2c2-flexcop-pci module you got a hardlock of your system.
This is due the usage of spin_lock before spin_lock_init is called.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:29 -03:00
Trent Piepho 990e3743b5 V4L/DVB (5504): Sn9c102: Make driver V4L2 not V4L1
sn9c102 is a v4l2 driver, except it used a couple v4l1 helper functions.
Stop using those functions and depend on V4L2 in Kconfig.
Acked-by: Luca Risolia <luca.risolia@studio.unibo.it>

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:29 -03:00
Trent Piepho 7e81d8254d V4L/DVB (5503): Sn9c102: declare constant byte sequences as static const
Makes sure they don't get copied onto the stack.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Acked-by: Luca Risolia <luca.risolia@studio.unibo.it>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:28 -03:00
Trent Piepho c680dd6038 V4L/DVB (5502): Sn9c102: more efficient register writing code
There were many places in the driver which had long sequences of constant
register initializations.  These were done with one function call per
register.  The register address and value were immediate values in the
function calls.
This is very inefficient, as each register and value take twice the space
when they are code, as each includes a push instruction to put it on
the stack.  There there is the overhead, both size and time, for a
function call for each register.  It's also quite a few lines of C code
to do this.
The patch creates a function that writes multiple registers from a list,
and a macro that makes it easy to construct a such a list as a const
static local to send to the function.
This gets rid of quite a bit of C code, and shrinks the driver by around
8k, while at the same time being more efficient.
Acked-by: Luca Risolia <luca.risolia@studio.unibo.it>

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:27 -03:00
Scott Alfter 1ebba670ed V4L/DVB (5497): Additional card support for bttv driver
SSAI (www.ssai.us) makes several Bt878-based capture cards that get used in our
surveillance, conferencing, and medical imaging systems.  The attached
relatively small patch adds support for these cards, which fall into two broad
* boards with one or more Bt878s, one or more composite inputs, and no S-video
  or tuner inputs
* boards with one Bt878, one composite input, one S-video input, and no tuner
  input

Signed-off-by: Scott Alfter <salfter@ssai.us>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:25 -03:00
Trent Piepho 4b9d4e7dba V4L/DVB (5494): Lgdt330x: Fix some warnings
It's KERN_WARNING "lgdt....", not "KERN_WARNING lgdt...."

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:24 -03:00
Jean Delvare 82c2e4617c V4L/DVB (5492): Remove useless includes of i2c-algo-bit.h
The tda7432, tda9875 and tvaudio media drivers don't need to include
the linux/i2c-algo-bit.h header file.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:23 -03:00
Jean Delvare e8f4e7525c V4L/DVB (5491): Cx88: Support the DTV1000 T analog inputs
Add support for the S-Video and CVBS (composite) analog video inputs
of the Leadtek WinFast DTV1000 T adapter.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:23 -03:00
Amit Choudhary fd51c697dd V4L/DVB (5490): Drivers/media/video/se401.c: check kmalloc() return value.
Check the return value of kmalloc() in function se401_start_stream(), in
file drivers/media/video/se401.c.

Signed-off-by: Amit Choudhary <amit2030@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:21 -03:00
Amit Choudhary 20ec811edd V4L/DVB (5489): Codec.c: check kmalloc() return value.
Signed-off-by: Amit Choudhary <amit2030@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:20 -03:00
Mauro Carvalho Chehab aaa40cb8b7 V4L/DVB (5488): Replace DMA magic mask for its aliases
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:20 -03:00
Ed Vipas 904ab884a2 V4L/DVB (5486): Add support for remote of Asustech P7131 Hybrid LNA
This patch just defines the remote control type.

Signed-off-by: Ed Vipas <epvipas@gmail.com>
Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:19 -03:00
Hartmut Hackmann 9971f4f1d3 V4L/DVB (5485): Tda827x: delayed probing of tuner version
When the tuner is attached, the tda10046 is not initilized yet, so it
is searching for its firmware. If the tuner is attached to the tda10046
silent i2c port, a bus collision can occur. Now the version is probed
during the first init or sleep call.

Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:17 -03:00
Hartmut Hackmann e65ec752ce V4L/DVB (5484): Set tda8290 to analog mode after init
Set tda8290 to analog mode after init, otherwise the tuner driver will 
not accept i.e. the standby command.

Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:15 -03:00
Jarod Wilson f992a497c7 V4L/DVB (5482): Bttv: automatically load dvb-bt8xx for bttv cards with dvb
This patch causes the bttv driver to automatically load the dvb-bt8xx module
for bttv/dvb hybrid cards. Successfully tested with a pcHDTV HD-2000 card.
This patch is based on the recent patches to enable autoloading of cx88-dvb,
cx88-blackbird and saa7134-dvb.

Signed-off-by: Jarod Wilson <jwilson@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:14 -03:00
Damian Minkov fbc8408a0d V4L/DVB (5481): Fix audio input for AverTv Go 007
Fix audio input source for capturing(playing) audio on AverTv Go 007 cards.

Signed-off-by: Damian Minkov <damencho@damencho.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:14 -03:00
Mauro Carvalho Chehab 66623a0419 V4L/DVB (5480): Fix cx88_print_irqbits calls to use ARRAY_SIZE
cx88_print_irqbits were expecting a string pointer with 32 bytes. Better 
to pass the string size and use ARRAY_SIZE on its calls.

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:13 -03:00
Mauro Carvalho Chehab 53c4e9551c V4L/DVB (5479): Use ARRAY_SIZE instead of a magic number
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:12 -03:00
Mauro Carvalho Chehab 5b9c4e6dbb V4L/DVB (5478): Use ARRAY_SIZE and a cleaner logic for initializing tuner
ATI HDTV Wonder needs to initialize some registers before allowing the
tuner to start working.
The current logic have lots of magic. This patch makes the code cleaner,
using ARRAY_SIZE() for the initialization array and using a
bidimensional array, instead of doing some stuff like:
	&buffer[i+2]

Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-04-27 15:45:11 -03:00