summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/pvrusb2/pvrusb2-encoder.c
AgeCommit message (Collapse)Author
2009-03-19fix mispelled Hauppauge in HD PVR and PVR USB2 driver commentsJanne Grunau
Priority: normal Signed-off-by: Janne Grunau <j@jannau.net>
2008-10-19pvrusb2: Keep MPEG PTSs from drifting awayMike Isely
From: Boris Dores <babal@via.ecp.fr> (Mike Isely) This change was empirically figured out by Boris Dores after empirically comparing against behavior in the Windows driver. Priority: normal Signed-off-by: Mike Isely <isely@pobox.com>
2008-05-25pvrusb2: Remove svn Id keyword from all sourcesMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2008-04-05pvrusb2: Implement critical digital streaming quirk for onair devicesMike Isely
From: Mike Isely <isely@pobox.com> Implement timed measurement of encoder operation for the first time it is run. This allows the driver to note when the encoder has been run successfully for at least 1/4 second. On top of that implement various bits to ensure that the encoder has been run once before digital streaming for OnAir devices. This is done via several core state machine tweaks. 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>
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-11-25pvrusb2: Soften the crashed encoder warning messageMike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 driver has been successfully recovering from a crashed encoder now for over 2 years. I think it's time to reduce the perceived severity of the warning message. While I'd still very much like to stop these crashes, the recovery logic is solid enough that the problem is effectively benign. No point in panicing the users over it. Signed-off-by: Mike Isely <isely@pobox.com>
2007-11-25pvrusb2: Centralize device specific attributes into a single place.Mike Isely
From: Mike Isely <isely@pobox.com> The pvrusb2 driver currently supports two variants of the Hauppauge PVR USB2. However there are other hardware types potentially supportable, but the driver at the moment is not structured to make it easy to describe these minor variations. This changeset is the first set of changes to make such additional device support possible. Device attributes are held in several tables all contained within pvrusb2-devattr.c; all other device-specific driver behavior now derives from these tables. Signed-off-by: Mike Isely <isely@pobox.com>
2007-11-25pvrusb2: Rework pipeline state controlMike Isely
From: Mike Isely <isely@pobox.com> This is a new implementation for video pipeline control within the pvrusb2 driver. Actual start/stop of the pipeline is moved to the driver's kernel thread. Pipeline stages are controlled autonomously based on surrounding pipeline or application control state. Kernel thread management is also cleaned up and moved into the internal control structure of the driver, solving a set up / tear down race along the way. Better failure recovery is implemented with this new control strategy. Also with this change comes better control of the cx23416 encoder, building on additional information learned about the peculiarities of controlling this part (this information was the original trigger for this rework). With this change, overall encoder stability should be considerably improved. Yes, this is a large change for this driver, but due to the nature of the feature being worked on, the changes are fairly pervasive and would be difficult to break into smaller pieces with any semblence of step-wise stability. Signed-off-by: Mike Isely <isely@pobox.com>
2007-10-14pvrusb2: Improve encoder chip health trackingMike Isely
From: Mike Isely <isely@pobox.com> This is a minor change to help with tracking the viability of the encoder chip within the PVR USB2 device. Signed-off-by: Mike Isely <isely@pobox.com>
2007-04-28pvrusb2: Improve handling of PAL-60 video standardMike Isely
From: Mike Isely <isely@pobox.com> 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>
2007-02-21make pvr2_encoder_prep_config() staticMauro Carvalho Chehab
From: Adrian Bunk <bunk@stusta.de> Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-19compat: Add -include linux/version.h to cflagsTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Add -include linux/version.h to the cflags. Now code can have backward compatibility test without including compat.h first. Linux headers included from compat.h are removed, so that code will get the same headers when compiling in v4l-dvb as it does in the kernel. Many drivers have compat.h moved to the end of their include list, as this lets compat.h do things it can't do at the beginning. Such as test of something is defined to include compat code, or to put a wrapper around a function without changing the function's name. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-02-07pvrusb2: Follow coding style convention for "#if 0" blocksMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-02-07pvrusb2: Fix printk format typoMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2007-02-02Http://linuxtv.org/hg/~mcisely/pvrusb2
From: Mauro Carvalho Chehab <mchehab@infradead.org> Follows the same coding style for commented code The latest patch series added a different way of commenting unused patches: #ifdef notdef But V4L/DVB coding style uses, instead: #if 0 This have also the advantage of not sending to mainstream those development codes that doesn't make sense at a production environment, while keeping them under development trees. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mike isely <isely@pobox.com>
2007-01-28pvrusb2: video corruption fixesMike Isely
From: Mike Isely <isely@pobox.com> Tweak the encoder setup in order to stop it from corrupting the video data when there is a disruption in the data flow (e.g. a channel change). Signed-off-by: Mike Isely <isely@pobox.com>
2007-01-28pvrusb2: encoder comm protocol cleanupMike Isely
From: Mike Isely <isely@pobox.com> Update the implementation of the communication protocol for operating the encoder, using updated knowledge about the encoder. Signed-off-by: Mike Isely <isely@pobox.com>
2007-01-21pvrusb2: Use macro names for FX2 commandsMike Isely
From: Michael Krufky <mkrufky@linuxtv.org> This is a maintainability cleanup; use nice names for all the FX2 commands instead of raw bytes. This way we can easily find where we issue FX commands. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mike Isely <isely@pobox.com>
2007-01-21Remove some warnings when compiling on x86_64Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> pvrusb2-encoder.c: In function 'pvr2_encoder_cmd': pvrusb2-encoder.c:195: warning: format '%u' expects type 'unsigned int', but argument 3 has type 'long unsigned int' pvrusb2-encoder.c:205: warning: format '%u' expects type 'unsigned int', but argument 3 has type 'long unsigned int' pvrusb2-encoder.c: In function 'pvr2_encoder_vcmd': pvrusb2-encoder.c:303: warning: format '%u' expects type 'unsigned int', but argument 3 has type 'long unsigned int' CC: Mike Isely <isely@isely.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-01-19pvrusb2: A patch to use ARRAY_SIZE macro when appropriateMike Isely
From: Ahmed S. Darwish <darwish.07@gmail.com> Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com> Signed-off-by: Mike Isely <isely@pobox.com>
2006-12-30pvrusb2: Stream configuration cleanupsMike Isely
From: Mike Isely <isely@pobox.com> Clean up and tighten logic involving stream configuration. This mainly involves changes to pvrusb2-v4l2.c, where we better clarify how we use the stream configuration enum and implement a cleaner means to control streaming for a given device node. Signed-off-by: Mike Isely <isely@pobox.com>
2006-12-27pvrusb2: Enable radio mode round #1Mike Isely
From: Pantelis Koukousoulas <pakt223@freemail.gr> This is the logic that supports switching modes via e.g., echo radio > /sys/class/pvrusb2/sn-*/ctl_input/cur_val. To do the mode switching we need to a) broadcast AUDC_SET_RADIO and b) issue the CX2341X_ENC_MUTE_VIDEO command to the encoder. The first is done by adding a new pvr2_i2c_op and having it trigger on input change, the second by adding this command in pvr2_encoder_start() and requesting an encoder restart on input change by setting stale_subsys_mask appropriately. The clues about AUDC_SET_RADIO and CX2341X_ENC_MUTE_VIDEO were kindly provided by Hans Verkuil on the pvrusb2 mailing list. The idea to implement mode switching this way (on input change) is due to Mike Isely. Why AUDC_SET_RADIO/VIDIOC_S_STD are used for switching? I can 't be sure, but I think this can be traced to a cornell student being the first to implement radio support in ivtv "as a different standard". I think the rest just evolved from there (it 's in the ivtv ML archives). --Pantelis Signed-off-by: Pantelis Koukousoulas <pakt223@freemail.gr> Signed-off-by: Mike Isely <isely@pobox.com>
2006-08-30Fix a typo.Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-06-30Clean out a zillion sparse warnings in pvrusb2Mauro Carvalho Chehab
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-06-27Fix warning when compiling on 64 bit machinesMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-06-25Implement use of cx2341x module in pvrusb2 driverMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2006-06-25Rearrange things in pvrusb2 driver in preparation for using cx2341x moduleMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2006-06-25Rearrange things in pvrusb2-encoder in preparation for use of cx2341x moduleMike Isely
From: Mike Isely <isely@pobox.com> Signed-off-by: Mike Isely <isely@pobox.com>
2006-06-18Add CX2341X MPEG encoder module.Hans Verkuil
From: Hans Verkuil <hverkuil@xs4all.nl> Adds the cx2341x.c module that handles the programming of the Conexant cx23415/6 MPEG encoder chip used by cx88-blackbird, pvrusb2 and ivtv. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2006-04-20cx23416 fix in pvrusb2 to allow xawtv to function againMike Isely
From: Mike Isely <isely@pobox.com> Tweak cx23416 configuration to permit xawtv to work again. This problem was introduced when the model 24xxx hardware support was added. The fix here repairs the problem while and is valid for both old and new hardware. Signed-off-by: Mike Isely <isely@pobox.com>
2006-04-20Change pvrusb2 subsystem definition bits for easier handlingMike Isely
From: Mike Isely <isely@pobox.com> Subsystem bits are defined as ordinal values now instead of bits in a mask. Signed-off-by: Mike Isely <isely@pobox.com>
2006-04-19Another rework of pvrusb2 video standard handlingMike Isely
From: Mike Isely <isely@pobox.com> Clean up logic for handling video standards in the pvrusb2 driver. New implementation should be able to handle all possible V4L defined video standards now, and it should be far easier to maintain this going forward. Signed-off-by: Mike Isely <isely@pobox.com>
2006-04-19Rework pvrusb2 internal controls implementationMike Isely
From: Mike Isely <isely@pobox.com> Rework controls internal architecture. Rework video standard handling. This is a major change. Signed-off-by: Mike Isely <isely@pobox.com>
2006-04-02Merge from http://linuxtv.org/hg/~hverkuil/v4l-dvbMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> merge: Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2006-03-31Move cx2341x.h to media/cx2341x.hHans Verkuil
From: Hans Verkuil <hverkuil@xs4all.nl> This header is used by multiple drivers, so keep it in include/media so all drivers can access it. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2006-03-28Major pvrusb2 rework to remove translationsMike Isely
From: Mike Isely <isely@pobox.com> Rework entire internal controls interface to eliminate the need for visibly defined control IDs which must otherwise be translated by the V4L2 public interface. As part of this work, internal structures which mimiced various V4L2 structures (video standards, audio modes) have been reworked to actually use the native structures. This triggered a _significant_ rework for how video standards are dealt with (and what is in place now should be much more flexible and forgiving for various handling less-common video standards). Signed-off-by: Mike Isely <isely@pobox.com>
2006-03-25Adjust cx23416 operation in pvrusb2 to work with model 24xxx hardwareMike Isely
From: Mike Isely <isely@pobox.com> This applies some changes to the logic which controls the cx23416 in pvrusb2. This is required in order for newer model 24xxx hardware to operate correctly and is backwards compatible with older hardware. Signed-off-by: Mike Isely <isely@pobox.com>
2006-03-11pvrusb2: remove "ifdef notdef"Michael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> - Changed all occurances of "#ifdef notdef" to "#if 0" - This code will remain visible in the v4l-dvb repositories, but will be held back from git. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2006-02-26moved pvrusb2 driver into the kernel treeMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>