summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/pvrusb2
AgeCommit message (Collapse)Author
2008-04-15Backport changeset 5fa1247a2b56f33f88432c24e109deaf91ef8281Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Original patch from Al Viro <viro@ftp.linux.org.uk> Date: Sat Mar 29 03:07:38 2008 +0000 NULL noise: drivers/media kernel-sync: Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-03-15pvrusb2: add new usb pid for 73xxx modelsMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2008-03-08pvrusb2: add new usb pid for 75xxx modelsMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2008-03-07pvrusb2: Fix compilation warningMike Isely
From: Mike Isely <isely@pobox.com> Fix use of a non-int (size_t) being passed in a printf width field. This benign issue has apparently been around for a long time, but went undetected until now. Signed-off-by: Mike Isely <isely@pobox.com>
2008-03-15tuner: rename TUNER_PHILIPS_ATSC to TUNER_PHILIPS_FCV1236DMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> TUNER_PHILIPS_ATSC is an ambiguous name for a tuner. Rename it to TUNER_PHILIPS_FCV1236D to be more descriptive. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2008-02-24pvrusb2: set default video standard to NTSC for OnAir HDTV / CreatorMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> The pvrusb2 driver normally picks up the default video standard from the eeprom on Hauppauge devices, but the OnAir HDTV and OnAir Creator are not Hauppauge devices, and do not store this information in any eeprom. These devices support NTSC/ATSC, so we should use NTSC by default when in analog mode. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2008-03-02pvrusb2: Fix storage-class as per C99 specMike Isely
From: Tobias Klauser <tklauser@distanz.ch> The C99 specification states in section 6.11.5: The placement of a storage-class specifier other than at the beginning of the declaration specifiers in a declaration is an obsolescent feature. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Rework context handling and initializationMike Isely
From: Mike Isely <isely@pobox.com> This change significantly rearranges pvr2_context level initialization and operation: 1. A new kernel thread is set up for management of the context. 2. Destruction of the pvr2_context instance is moved into the kernel thread. No other context is able to remove the instance; doing this simplifies lock handling. 3. The callback into pvrusb2-main, which is used to trigger initialization of each interface, is now issued from this kernel thread. Previously it had been indirectly issued out of the work queue thread in pvr2_hdw, which led to deadlock issues if the interface needed to change a control setting (which in turn requires dispatch of another work queue entry). 4. Callbacks into the interfaces (via the pvr2_channel structure) are now issued strictly from this thread. The net result of this is that such callback functions can now also safely operate driver controls without deadlocking the work queue. (At the moment this is not actually a problem, but I'm anticipating issues with this in the future). 5. There is no longer any need for anyone to enter / exit the pvr2_context structure. Implementation of the kernel thread here allows this all to be internal now, simplifying other logic. 6. A very very longstanding issue involving a mutex deadlock between the pvrusb2 driver and v4l should now be solved. The deadlock involved the pvr2_context mutex and a globals-protecting mutex in v4l. During initialization the driver would take the pvr2_context mutex first then the v4l2 interface would register with v4l and implicitly take the v4l mutex. Later when v4l would call back into the driver, the two mutexes could possibly be taken in the opposite order, a situation that can lead to deadlock. In practice this really wasn't an issue unless a v4l app tried to start VERY early after the driver appeared. However it still needed to be solved, and with the use of the kernel thread relieving need for pvr2_context mutex, the problem should be finally solved. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Eliminate timer race during tear-downMike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 tear-down logic was clearing two timers before stopping its internal work queue. That left a tiny window open where the work queue might run after the timers are stopped, possibly starting them again. This could lead to dangling pointers and an oops. Solution: Kill the work queue first, then delete the timers. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Close potential race condition during initializationMike Isely
From: Mike Isely <isely@pobox.com> There is a callback that is issued to into pvr2_context from pvr2_hdw after initialization is done. There was a probability that this callback could get missed. Fixed. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Remove dead codeMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Increase buffer size for printing video standard stringsMike Isely
From: Mike Isely <isely@pobox.com> Buffer size for printing pvrusb2 video standard strings was too small before. This is cosmetic; the printing logic is not able to overrun a too-short buffer. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Handle ATSC video standard bitsMike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 driver dynamically generates an enumeration of support video standard combinations based on which video standard bits are set. ATSC modes don't fall into this since they are by nature not analog. The pvrusb2 driver has been warning about an inability to classify ATSC standards. This change causes the classification algorithm to ignore any ATSC standards (such things are better handled elsewhere anyway). Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Add Gotview USB 2.0 DVD Deluxe to supported devicesMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Make device attribute structure more compactMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Make LED control into a device-specific attributeMike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 driver has used hardcoded logic to control the LED on the device. However this is really Hauppauge-specific behavior. This change defines a new device attribute for LED control and sets things up appropriately for Hauppauge devices. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-09pvrusb2: Indicate streaming status via LEDMike Isely
From: Mike Isely <isely@pobox.com> Most of this originates from Michael Krufky <mkrufky@linuxtv.org>; these changes move LED control into separate functions. This is the first step in new work to make LED control a device-specific attribute. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-06pvrusb2: Allow digital streaming without encoder firmwareMike Isely
From: Mike Isely <isely@pobox.com> The encoder is not a part of the pipeline when in digital mode, so streaming is OK in this case even when the encoder's firmware is not loaded. Modify the driver core handling of this scenario to permit streaming. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: trace print cosmetic cleanup / improvementsMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Enhance core logic to also control digital streamingMike Isely
From: Mike Isely <isely@pobox.com> This is a major pvrusb2 change. The driver core has an algorithm that is used to cleanly sequence the changes needed to enable / disable video streaming. The algorithm had originally been written for analog streaming, but when in digital mode the pipeline is considerably different - for example the mpeg encoder is not used. These changes to the core logic implement correct pipeline control when in digital mode. Knowing which pipeline to handle and how to handle it is completely driven by the current input selection. So, in theory, to perform digital stream now all one has to do is switch input to dtv and start streaming as usual. Well, in theory. The reality is that digital tuner and demod control are still not in the driver core yet so until that is present there's nothing to actually stream. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Define digital control scheme device attributesMike Isely
From: Mike Isely <isely@pobox.com> Unlike analog control, control of the digital side is not nearly as uniform among different devices. So we have to specify the correct digital control scheme as a new device attribute. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: New functions for additional FX2 digital-related commandsMike Isely
From: Mike Isely <isely@pobox.com> This code is actually part of a larger set from Mike Krufky <mkrufky@linuxtv.org>, to support ATSC streaming from within the pvrusb2 driver. More to come... Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Fix oops possible when claiming a NULL streamMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: whitespace fixupMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: add function pvr2_hdw_cmd_powerdownMike Isely
From: Michael Krufky <mkrufky@linuxtv.org> Call pvr2_hdw_cmd_powerdown to power down the device Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Ensure that default input selection is actually validMike Isely
From: Mike Isely <isely@pobox.com> Previously the pvrusb2 driver just started with the default input to be "television". But if the device doesn't support an analog tuner then this default must be different. New logic here selects a reasonable default based on the actual valid set of available inputs. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Improve control validation for enumerationsMike Isely
From: Mike Isely <isely@pobox.com> When an enumeration control is changed, the pvrusb2 driver assumed that the enumeration values were continuous. That is no longer true; this change allows for properly input validation even when not all enumeration values are legal (which can happen with input selection based on what the hardware supports). Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Implement addition sysfs tracingMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: v4l2 implementation fixes for input selectionMike Isely
From: Mike Isely <isely@pobox.com> Now that the pvrusb2 driver can dynamically choose which inputs to make available depending on the hardware, the enumeration of input choices is no longer a contiguous range of integers. Unfortunately this causes a problem in the v4l2 implementation since the input enumeration requires continuity in the API. This change implements a mapping in order to preserve the v4l2 interface requirement. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Improve logic which handles input choice availabilityMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Account for dtv choice (a bit) in v4l2 implementationMike Isely
From: Mike Isely <isely@pobox.com> The v4l2 implementation in pvru2b2 must produce a sane answer when asked, when the input choice is set to dtv. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Dynamically control range of input selectionsMike Isely
From: Mike Isely <isely@pobox.com> This follows from defining the available inputs as device attributes. This change causes the driver to adjust its list of inputs based on those attributes. Now, for example, the FM radio will appear as a choice only if the hardware supports an FM radio. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: Define device attributes for all input modesMike Isely
From: Mike Isely <isely@pobox.com> Different devices support different input types. Up until now we've really been assuming that everyone has an analog tuner, an FM radio, composite, and s-video inputs. But as we add other devices, these assumptions are no longer true. The way to deal with this is to define the available inputs as additional device attributes, so that the driver can adjust its internal behavior accordingly. Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-03pvrusb2: add device attributes for fm radio and digital tunerMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-02-05backport kernel commit c84e6036ba7177a404cc860cb5a440e06fad92ddMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Original changelog: Author: Joe Perches <joe@perches.com> Date: Sun Feb 3 17:18:59 2008 +0200 drivers/media/: Spelling fixes kernel-sync: Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-01-27[PATCH] static memoryDouglas Schilling Landgraf
From: Douglas Schilling Landgraf <dougsland@gmail.com> - Static memory is always initialized with 0. - Replaced in some cases C99 comments for /* */ Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com>
2008-01-13Kconfig: add missing selections for VIDEO_PVRUSB2Michael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> VIDEO_PVRUSB2 must select: VIDEO_SAA711X, VIDEO_CX25840, VIDEO_MSP3400, and VIDEO_WM8775 Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Acked-by: Mike Isely <isely@pobox.com>
2007-10-25pvrusb2: add support for Hauppauge WinTV PVR-USB2 Model 75xxxMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Create a device description and enable autodetection for Hauppauge WinTV PVR-USB2 Model 75xxx Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-12cx2341x: command argument should be u32 instead of int.Hans Verkuil
From: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2007-12-10backout a backward compatibility patch that shouldn't go to masterMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> >> I recommend applying all except for the topmost patch: >> >> pvrusb2: Fix compilation for OnAir Creator config >> >> This is a backwards-compat patch that is not needed within the v4l-dvb >> repository nor the upstream kernel, but *is* needed within the pvrusb2 >> svn repository. >> > > Agreed. Just don't pull that. I will deal with the issue in svn later. > -Mike Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-12-08pvrusb2: Fix compilation for OnAir Creator configMike Isely
From: Mike Isely <isely@pobox.com> The OnAir creator configuration calls for a specific tuner type to be declared. However for some old kernels that tuner type was named differently. This change adapts to the older name, when present. Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: rework device descriptor layoutMike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 driver tries to keep all device specific attributes in a single data structure in one source file. This change further cleans up how that table is set up. We now try to group everything together for each specific device, and the number of symbols exported from this module has now been reduced to a single global. Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: Remove obsolete (and misleading) commentMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: Remove old obsolete CONFIG flags for pvrusb2 driver.Mike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: Device CONFIG flags for OnAir device supportMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: Implement experimental support for OnAir Creator and USB2 devicesMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-08pvrusb2: Mark Gotview hardware as having a cx2584x partMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-02pvrusb2: Recognize ATSC video standard bit valuesMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-02pvrusb2: minor rework for default video standard handlingMike Isely
From: Mike Isely <isely@pobox.com> pvrusb2: When a per-device-type default video standard is declared, handle it in such a way that it can be correctly and unambiguously reported in the system log. Signed-off-by: Mike Isely <isely@pobox.com>
2007-12-02pvrusb2: Expand comment in device attributes description.Mike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>