summaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cx23885
Commit message (Collapse)AuthorAgeFilesLines
* [media] rename most media/video pci drivers to media/pciMauro Carvalho Chehab2012-08-1532-15531/+0
| | | | | | | | Rename all PCI drivers with their own directory under drivers/media/video into drivers/media/pci and update the building system. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] common: move media/common/tuners to media/tunersMauro Carvalho Chehab2012-08-131-1/+1
| | | | | | | Move the tuners one level up, as the "common" directory will be used by drivers that are shared between more than one driver. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] move the dvb/frontends to drivers/media/dvb-frontendsMauro Carvalho Chehab2012-08-131-1/+1
| | | | | | | Raise the DVB frontends one level up, as the intention is to remove the drivers/media/dvb directory. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] dvb: move the dvb core one level upMauro Carvalho Chehab2012-08-131-1/+1
| | | | | | | just like the V4L2 core, move the DVB core to drivers/media, as the intention is to get rid of both "video" and "dvb" directories. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] dvb: get rid of fe_ioctl_override callbackMauro Carvalho Chehab2012-08-131-2/+1
| | | | | | | | | | | | | | | This callback were meant to allow overriding a FE callback, before its call, but it is not really needed, as the callback can be intercepted after tuner attachment. Worse than that, only DVBv3 calls are intercepted this way, so a DVBv5 application will produce different effects than a DVBv3 one. So, get rid of it. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Acked-by: Antti Palosaari <crope@iki.fi> Reviewed-by: Antti Palosaari <crope@iki.fi>
* [media] Add support for the Terratec Cinergy T Dual PCIe IR remoteDjuri Baars2012-07-312-0/+13
| | | | | | | | The following patch adds support for the infrared remote included in the Terratec Cinergy T Dual PCIe card. Signed-off-by: Djuri Baars <dsbaars@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Declare MODULE_FIRMWARE usageTim Gardner2012-07-311-0/+2
| | | | | | | Cc: Steven Toth <stoth@kernellabs.com> Cc: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Replace struct memcpy with struct assignmentEzequiel García2012-07-301-5/+2
| | | | | | | | Copying structs by assignment is type safe. Plus, is shorter and easier to read. Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Remove useless struct i2c_algo_bit_dataEzequiel García2012-07-302-5/+0
| | | | | | | | | | | The field 'struct i2c_algo_bit_data i2c_algo' is wrongly confused with struct i2c_algorithm. Moreover, i2c_algo field is not used since i2c is registered using i2c_add_adpater() and not i2c_bit_add_bus(). Therefore, it's safe to remove it. Tested by compilation only. Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Silence unknown command warningsAnton Blanchard2012-07-061-1/+1
| | | | | | | | | | I am seeing a constant stream of warnings on my cx23885 based card: cx23885_tuner_callback(): Unknown command 0x2. Add a check in cx23885_tuner_callback to silence it. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: add support for HVR-1255 analog (cx23888 variant)Devin Heitmueller2012-07-064-2/+69
| | | | | | | | | | | | | | | | | Get the HVR-1255 analog support working for all supported inputs. This includes introduction of a new board profile for an OEM variant which doesn't have all the same inputs as the retail version of the board. Validated with the following boards: HVR-1255 (0070:2259) Thanks to Steven Toth and Hauppauge for loaning me various boards to regression test with. Thanks-to: Steven Toth <stoth@kernellabs.com> Signed-off-by: Devin Heitmueler <dheitmueller@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: make analog support work for HVR_1250 (cx23885 variant)Devin Heitmueller2012-07-062-8/+24
| | | | | | | | | | | | | | | | | | | | The analog support in the cx23885 driver was completely broken for the HVR-1250. Add the necessary code. Note that this only implements analog for the composite and s-video inputs. The tuner input continues to be non-functional due to a lack of analog support in the mt2131 driver. Validated with the following boards: HVR-1250 (0070:7911) Thanks to Steven Toth and Hauppauge for loaning me various boards to regression test with. Thanks-to: Steven Toth <stoth@kernellabs.com> Signed-off-by: Devin Heitmueler <dheitmueller@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: TeVii s471 card supportIgor M. Liplianin2012-05-204-0/+24
| | | | | | | The card is similar to TeVii s470, but has different LNB power control. Signed-off-by: Igor M. Liplianin <liplianin@me.by> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l: fix compiler warningsHans Verkuil2012-05-141-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | media_build/v4l/au0828-video.c: In function 'au0828_irq_callback': media_build/v4l/au0828-video.c:123:6: warning: variable 'rc' set but not used [-Wunused-but-set-variable] media_build/v4l/cx23888-ir.c: In function 'pulse_clocks_to_clock_divider': media_build/v4l/cx23888-ir.c:334:6: warning: variable 'rem' set but not used [-Wunused-but-set-variable] media_build/v4l/cx25840-ir.c: In function 'pulse_clocks_to_clock_divider': media_build/v4l/cx25840-ir.c:319:6: warning: variable 'rem' set but not used [-Wunused-but-set-variable] media_build/v4l/cx25840-ir.c: In function 'cx25840_ir_tx_write': media_build/v4l/cx25840-ir.c:863:21: warning: variable 'c' set but not used [-Wunused-but-set-variable] media_build/v4l/em28xx-audio.c: In function 'snd_em28xx_hw_capture_params': media_build/v4l/em28xx-audio.c:346:31: warning: variable 'format' set but not used [-Wunused-but-set-variable] media_build/v4l/em28xx-audio.c:346:25: warning: variable 'rate' set but not used [-Wunused-but-set-variable] media_build/v4l/em28xx-audio.c:346:15: warning: variable 'channels' set but not used [-Wunused-but-set-variable] media_build/v4l/hdpvr-control.c: In function 'get_input_lines_info': media_build/v4l/hdpvr-control.c:98:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] media_build/v4l/hdpvr-video.c: In function 'hdpvr_try_ctrl': media_build/v4l/hdpvr-video.c:955:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] media_build/v4l/saa7134-video.c: In function 'saa7134_s_tuner': media_build/v4l/saa7134-video.c:2030:6: warning: variable 'rx' set but not used [-Wunused-but-set-variable] media_build/v4l/sn9c102_core.c: In function 'sn9c102_stream_interrupt': media_build/v4l/sn9c102_core.c:998:7: warning: variable 'timeout' set but not used [-Wunused-but-set-variable] Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Janne Grunau <j@jannau.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Don't duplicate xc4000 entry for radioMiroslav Slugen2012-01-161-2/+2
| | | | | | | | | | | | All radio tuners in cx23885 driver using same address for radio and tuner, so there is no need to probe it twice for same tuner and we can use radio_type UNSET. Be aware radio support in cx23885 is not yet committed, so this is only minor fix for future support. Signed-off-by: Miroslav Slugen <thunder.mmm@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885-dvb: check if dvb_attach() succededMiroslav Slugen2012-01-161-0/+5
| | | | | | | | | Fix possible null dereference for Leadtek DTV 3200H XC4000 tuner when no firmware file available. Cc: stable@kernel.org Signed-off-by: Miroslav Slugen <thunder.mmm@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: handle errors from videobuf_dvb_get_frontend()Dan Carpenter2012-01-161-3/+4
| | | | | | | | The error handling in the original code wasn't complete so static checkers complained about a potential NULL deference. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Query the CX25840 during enum_input for statusSteven Toth2012-01-101-0/+9
| | | | | | | | We can pass a NO_SIGNAL video decoder state back to applications if it's available. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: add Terratec Cinergy T PCIe dualStefan Ringel2012-01-073-0/+65
| | | | | Signed-off-by: Stefan Ringel <linuxtv@stefanringel.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Bugfix /sys/class/video4linux/videoX/name truncationSteven Toth2012-01-052-4/+4
| | | | | | | | | | | | | | | | The card names are being truncated in the video4linux sys class name file. Prior to this patch they were shown as: cx23885[0] mpeg (Hauppauge WinT cx23885[0] video (Hauppauge WinT cx23885[0] vbi (Hauppauge WinT After this patch they are shown as: Hauppauge WinTV-HVR1850 (video) Hauppauge WinTV-HVR1850 (mpeg) Hauppauge WinTV-HVR1850 (vbi) Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Control cleanup on the MPEG EncoderSteven Toth2012-01-051-65/+36
| | | | | | | | | | | Added three new control calls (g_std, querystd and g_ctrl) to the -417 driver. Also routed other controls through the main cx23885 driver meaning that the controls for the 417 and the raw video device all enter the driver code and are handled in a single place. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Hauppauge HVR1850 Analog driver supportSteven Toth2012-01-055-34/+197
| | | | | | | | | | | | | | | | | | | | | | First in a series of patches that adds support to the cx23885 driver for CX23888 analog video handling. Raw and MPEG video support is being added for the HVR1850 driver in the patch, and the following series of patches. Some basic cx23885 driver cleanup. Partly to add HVR1850 support and partly to allow -417.c V4L2 calls to be routed through thr driver core and handled in a single place. Make a number of core driver functions available to the -417.c driver to streamline the driver. Add the analog tuner ops definition so we can reach/tune the hardware when we need to. Added the tff field so 888 based cards (which have a weird field ordering issue) can be accomodated and worked around in the driver. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Configure the MPEG encoder early to avoid jerky videoSteven Toth2012-01-041-6/+14
| | | | | | | | | | | | | Found an odd bug while implementing support for the HVR1850 that lead to jerky video during the first capture, if the encoder was not initialized early. I've modied the driver to configure the encoder early, and this avoids the issue - a reasonable workaround. Regression tested against the HVR1800 and soon to be added HVR1850 [mchehab@redhat.com: Fix this compilation issue: drivers/media/video/cx23885/cx23885-417.c:1351:2: error: too few arguments to function ‘cx23885_initialize_codec’] Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Ensure the MPEG encoder height is configured from the normSteven Toth2012-01-041-0/+6
| | | | | | | | Bugfix: The height was not always correctly configured if switching between different video standards. Change the encode height based on the standard. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Cleanup MPEG encoder GPIO handlingSteven Toth2012-01-041-2/+10
| | | | | | | | | During initialization the prior GPIO's were not being preserved and restore correctly. Small cleanups to configure the GPIO's for the HVR1700, HVR1800 and HVR1850. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx25840 / cx23885: Fixing audio/volume regressionSteven Toth2012-01-041-3/+3
| | | | | | | | | | | Since the conversion to subdev in Oct 2010 the audio controls have not functioned correctly in the cx23885 driver. Passing values of 0-3f did not translate into meaningfull register writes. I've converted the cx23885 driver to match the cx25840 volume control definition and now audio is working reliably again. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885-dvb: Remove a dirty hack that would require DVBv3Mauro Carvalho Chehab2011-12-311-29/+12
| | | | | | | | | | | | | | | | | The cx23885-dvb driver has a dirty hack: 1) it hooks the DVBv3 legacy call to FE_SET_FRONTEND; 2) it uses internally the DVBv3 struct to decide some configs. Replace it by a change during the gate control. This will likely work, but requires testing. Anyway, the current way will break, as soon as we stop copying data for DVBv3 for pure DVBv5 calls. Compile-tested only. Cc: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: add support for Mygica X8507Alfredo Jesús Delaiti2011-11-243-1/+39
| | | | | | | | | | | | | | This patch supports card Mygica X8507 (analog part) This controller is a copy of driver card Mygica X8506 This patch depends on patch cx23885-alsa To do: FM, ISDB-t, remote control, audio for composite1, S-Video and video component. Signed-off-by: Alfredo J. Delaiti <alfredodelaiti@netscape.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] video: Drop undue references to i2c-algo-bitJean Delvare2011-11-241-1/+1
| | | | | | | | | | | | | | | | | There's one comment that has been copied from bttv to many other media/video drivers: /* init + register i2c algo-bit adapter */ Meanwhile, many drivers use hardware I2C implementations instead of relying on i2c-algo-bit, so this comment is misleading. Remove the reference to "algo-bit" from all drivers, to avoid any confusion. This is the best way to ensure that the comments won't go out of sync again. Anyone interested in the implementation details would rather look at the code itself. Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Stop the risc video fifo before reconfiguring itSteven Toth2011-10-141-0/+3
| | | | | | | | Safety reasons. We shouldn't be trying to reconfigure a risc processor instruction queue unless it's stopped. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Avoid incorrect error handling and reportingSteven Toth2011-10-141-10/+10
| | | | | | | | | | | | | | | | | | | | | | Previous driver over-reported errors and stopped the video fifo (causing video to stop) if 1) A risc error occured 2) The risc processor detected that it has missing lines in the video frame 3) The risc fifo is about to overflow. The previous driver reported all three of these cases as risc errors when this is technically not correct. So, the function was cleaned up. 1. Ensure that risc opcode related errors are correctly shown as such, and not overly reported for non-risc-opcode cases. 2. Ensure that line sync and overflow errors are not reported as opcode errors. 3. Ensure that only the risc-op-code case can stop the fifo and dump channel / risc processor information. The net result is that if video becomes unstable, cable disconnect, this will not trigger a stop of the video firmware (due to missing lines errors). Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Avoid stopping the risc engine during buffer timeoutSteven Toth2011-10-141-4/+0
| | | | | | | | | | | 1. Removed the verbose 'dump channel state to console', very noisy in weak signal conditions. 2. No need for the video buffer timeout to stop the risc engine here. Clearer and easier to maintain if start_video_dma() is the single place that this is done. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Removed a spurious function cx23885_set_scale()Steven Toth2011-10-141-8/+0
| | | | | | | Unused function removed. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: v4l2 api compliance, set the audioset field correctlySteven Toth2011-10-141-0/+5
| | | | | | | | Inform applications that multiple audio inputs are available on non-tv inputs. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: hook the audio selection functions into the main driverSteven Toth2011-10-141-15/+25
| | | | | | | | | | Ensure audio is established at driver start. Ensure the correct defaults are established for the audio path if the cards struct has nothing defined. Allow the caller to select one of the two baseband input paths. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: add generic functions for dealing with audio input selectionSteven Toth2011-10-142-0/+82
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: fixes related to maximum number of inputs and range checkingSteven Toth2011-10-141-2/+5
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Initial support for the MPX-885 mini-cardSteven Toth2011-10-143-1/+29
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Enable audio line in support from the back panelSteven Toth2011-10-142-0/+79
| | | | | | | | Add code to program the flatiron internal i2c ADC and pass the appropriate audio mux enums to the cx25840 driver. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Allow the audio mux config to be specified on a per input basisSteven Toth2011-10-141-0/+1
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Name an internal i2c part and declare a bitfield by nameSteven Toth2011-10-142-0/+2
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Ensure VBI buffers timeout quickly - bugfix for vbi hangs ↵Steven Toth2011-10-141-2/+2
| | | | | | | during streaming Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: remove channel dump diagnostics when a vbi buffer times outSteven Toth2011-10-141-2/+0
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: ensure video is streaming before allowing vbi to streamSteven Toth2011-10-141-0/+8
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: Ensure the VBI pixel format is established correctlySteven Toth2011-10-141-3/+25
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: add vbi buffer formatting, window changes and video core ↵Steven Toth2011-10-144-6/+62
| | | | | | | changes Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: vbi line window adjustmentsSteven Toth2011-10-141-3/+16
| | | | | | | Coding style and printk's cleaned up in following patches. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: minor printk cleanups and device registrationSteven Toth2011-10-141-1/+14
| | | | | Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: initialize VBI support in the core, add IRQ support, ↵Steven Toth2011-10-141-13/+55
| | | | | | | | | register vbi device Coding style and printk's are cleaned up in subsequent patches Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] cx23885: initial support for VBI with the cx23885Steven Toth2011-10-144-6/+47
| | | | | | | A handlful of coding style issue cleaned up in the following patches. Signed-off-by: Steven Toth <stoth@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>