summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-08-11[media] stv0367: Refine i2c error trace to include i2c addressPeter Griffin
When using stv0367 demodulator with STi STB platforms, we can have easily have four or more stv0367 demods running in the system at one time. As typically the b2120 reference design ships with a b2004a daughter board, which can accept two dvb NIM cards, and each b2100A NIM has 2x stv0367 demods and 2x NXPs tuner on it. In such circumstances it is useful to print the i2c address on error messages to know which one is failing due to I2C issues. Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] ascot2e: don't use variable length arraysMauro Carvalho Chehab
The Linux stack is short; we need to be able to count the number of bytes used at stack on each function. So, we don't like to use variable-length arrays, as complained by smatch: drivers/media/dvb-frontends/horus3a.c:57:19: warning: Variable length array is used. The max usecase of the driver seems to be 10 bytes + 1 for the register. So, let's be safe and allocate 11 bytes for the write buffer. This should be enough to cover all cases. If not, let's print an error message. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] horus3a: don't use variable length arraysMauro Carvalho Chehab
The Linux stack is short; we need to be able to count the number of bytes used at stack on each function. So, we don't like to use variable-length arrays, as complained by smatch: drivers/media/dvb-frontends/horus3a.c:57:19: warning: Variable length array is used. The max usecase of the driver seems to be 5 bytes + 1 for the register. So, let's be safe and allocate 6 bytes for the write buffer. This should be enough to cover all cases. If not, let's print an error message. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] cxd2841er: don't use variable length arraysMauro Carvalho Chehab
The Linux stack is short; we need to be able to count the number of bytes used at stack on each function. So, we don't like to use variable-length arrays, as complained by smatch: drivers/media/dvb-frontends/cxd2841er.c:205:19: warning: Variable length array is used. The max usecase of the driver seems to be 15 bytes + 1 for the register. So, let's be safe and allocate 17 bytes for the write buffer. This should be enough to cover all cases. If not, let's print an error message. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] netup_unidvb: NetUP Universal DVB-S/S2/T/T2/C PCI-E card driverKozlov Sergey
Add NetUP Dual Universal CI PCIe board driver. The board has - two CI slots - two I2C adapters - SPI master bus for accessing flash memory containing FPGA firmware No changes required. Signed-off-by: Kozlov Sergey <serjk@netup.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] cxd2841er: declare static functions as suchMauro Carvalho Chehab
drivers/media/dvb-frontends/cxd2841er.c:992:5: warning: no previous prototype for 'cxd2841er_get_carrier_offset_t2' [-Wmissing-prototypes] int cxd2841er_get_carrier_offset_t2( ^ drivers/media/dvb-frontends/cxd2841er.c:1032:5: warning: no previous prototype for 'cxd2841er_get_carrier_offset_c' [-Wmissing-prototypes] int cxd2841er_get_carrier_offset_c( ^ drivers/media/dvb-frontends/cxd2841er.c:1360:5: warning: no previous prototype for 'cxd2841er_read_snr_t2' [-Wmissing-prototypes] int cxd2841er_read_snr_t2(struct cxd2841er_priv *priv, u32 *snr) ^ Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] cxd2841er: Sony CXD2841ER DVB-S/S2/T/T2/C demodulator driverKozlov Sergey
Add DVB-C/T/T2/S/S2 demodulator frontend driver Sony CXD2841ER chip. Signed-off-by: Kozlov Sergey <serjk@netup.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] lnbh25: LNBH25 SEC controller driverKozlov Sergey
Add DVB SEC frontend driver for STM LNBH25PQR chip. [mchehab@osg.samsung.com: fix merge conflict: fe_sec_voltage_t should not be used in kernelspace anymore. instead, it should use enum fe_sec_voltage] Signed-off-by: Kozlov Sergey <serjk@netup.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] ascot2e: Sony Ascot2e DVB-C/T/T2 tuner driverKozlov Sergey
Add DVB-T/T2/C frontend driver for Sony Ascot2e (CXD2861ER) chip. Signed-off-by: Kozlov Sergey <serjk@netup.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] horus3a: Sony Horus3A DVB-S/S2 tuner driverKozlov Sergey
Add DVB-S/S2 frontend driver for Sony Horus3A (CXD2832AER) chip Signed-off-by: Kozlov Sergey <serjk@netup.ru> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] Technisat SkyStar USB HD,(DVB-S/S2) too much URBs for arm devicesChristian Löpke
Using 8 URBs results in a consecutive buffer allocation of too much memory for some arm devices. As we use isochronuous transfers the number of URBs can be reduced without risking data-loss. Signed-off-by: Christian Loepke <loepke@edfritsch.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] rc-core: improve the lirc protocol reportingDavid Härdeman
Commit 275ddb40bcf686d210d86c6718e42425a6a0bc76 removed the lirc "protocol" but kept backwards compatibility by always listing the protocol as present and enabled. This patch further improves the logic by only listing the protocol if the lirc module is loaded (or if lirc is builtin). Signed-off-by: David Härdeman <david@hardeman.nu> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] staging: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] staging: iio: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] staging: media: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] tuners: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] radio: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] i2c: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] dvb-frontends: Drop owner assignment from platform_driverKrzysztof Kozlowski
platform_driver does not need to set an owner because platform_driver_register() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] dvb-frontends: Drop owner assignment from i2c_driverKrzysztof Kozlowski
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] pctv452e: Replace memset with eth_zero_addrVaishali Thakkar
Use eth_zero_addr to assign the zero address to the given address array instead of memset when second argument is address of zero. Note that the 6 in the third argument of memset appears to represent an ethernet address size (ETH_ALEN). The Coccinelle semantic patch that makes this change is as follows: // <smpl> @eth_zero_addr@ expression e; @@ -memset(e,0x00,6); +eth_zero_addr(e); // </smpl> Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] tuners: Make all TV tuners visible if COMPILE_TEST=yGeert Uytterhoeven
Make the TV tuners menu visible when compile-testing, to allow selecting additional drivers on top of the drivers that are already automatically selected if MEDIA_SUBDRV_AUTOSELECT is enabled. Without this, many drivers stay disabled during e.g. allmodconfig. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] ttpci: Replace memset with eth_zero_addrVaishali Thakkar
Use eth_zero_addr to assign the zero address to the given address array instead of memset when second argument is address of zero. Note that the 6 in the third argument of memset appears to represent an ethernet address size (ETH_ALEN). The Coccinelle semantic patch that makes this change is as follows: // <smpl> @eth_zero_addr@ expression e; @@ -memset(e,0x00,6); +eth_zero_addr(e); // </smpl> Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] usb/airspy: removing unneeded gotoManinder Singh
This patch removes unneded goto, reported by coccinelle. Signed-off-by: Maninder Singh <maninder1.s@samsung.com> Reviewed-by: Akhilesh Kumar <akhilesh.k@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] i2c: Make all i2c devices visible if COMPILE_TEST=yGeert Uytterhoeven
Make the i2c devices menu visible when compile-testing, to allow selecting additional drivers on top of the drivers that are already automatically selected if MEDIA_SUBDRV_AUTOSELECT is enabled. Without this, many drivers stay disabled during e.g. allmodconfig. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] dvb-frontends: Make all DVB Frontends visible if COMPILE_TEST=yGeert Uytterhoeven
Make the DVB Frontends menu visible when compile-testing, to allow selecting additional drivers on top of the drivers that are already automatically selected if MEDIA_SUBDRV_AUTOSELECT is enabled. Without this, many drivers stay disabled during e.g. allmodconfig. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] x86/mm/pat, drivers/media/ivtv: move pat warn and replace WARN() ↵Luis R. Rodriguez
with pr_warn() On built-in kernels this warning will always splat as this is part of the module init. Fix that by shifting the PAT requirement check out under the code that does the "quasi-probe" for the device. This device driver relies on an existing driver to find its own devices, it looks for that device driver and its own found devices, then uses driver_for_each_device() to try to see if it can probe each of those devices as a frambuffer device with ivtvfb_init_card(). We tuck the PAT requiremenet check then on the ivtvfb_init_card() call making the check at least require an ivtv device present before complaining. Reported-by: Fengguang Wu <fengguang.wu@intel.com> [0-day test robot] Signed-off-by: Luis R. Rodriguez <mcgrof@suse.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] s5c73m3: Remove redundant spi driver bus initializationAntonio Borneo
In ancient times it was necessary to manually initialize the bus field of an spi_driver to spi_bus_type. These days this is done in spi_register_driver(), so we can drop the manual assignment. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] pci/Kconfig: don't use MEDIA_ANALOG_TV_SUPPORT for grabber cardsKrzysztof Hałasa
I noticed certain cards are currently under MEDIA_ANALOG_TV_SUPPORT but it seems they are frame grabbers (with CVBS, Svideo etc. inputs) rather than TV receivers (with analog TV tuners). MEDIA_CAMERA_SUPPORT maybe isn't the best name (only "meye" driver seems to drive a real camera in a laptop) but it at least doesn't select the TUNERs. Perhaps the following patch would make sense. Signed-off-by: Krzysztof Ha?asa <khalasa@piap.pl> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] mantis: remove an uneeded gotoMauro Carvalho Chehab
Gotos makes a little harder to check the code. In this particular case, the goto is doing nothing but jumping into a return. Instead, just replace the goto by the return, making it simpler. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] mantis: Fix error handling in mantis_dma_init()Fabio Estevam
Current code assigns 0 to variable 'err', which makes mantis_dma_init() to return success even if mantis_alloc_buffers() fails. Fix it by checking the return value from mantis_alloc_buffers() and propagating it in the case of error. Reported-by: RUC_Soft_Sec <zy900702@163.com> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] mt9v032: fix uninitialized variable warningHans Verkuil
drivers/media/i2c/mt9v032.c: In function ‘mt9v032_probe’: CC [M] drivers/media/i2c/s5k4ecgx.o drivers/media/i2c/mt9v032.c:996:20: warning: ‘pdata’ may be used uninitialized in this function [-Wmaybe-uninitialized] if (pdata && pdata->link_freqs) { ^ It can indeed be uninitialized in one corner case. Initialize to NULL. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] v4l2: move tracepoint generation into separate filePhilipp Zabel
To compile videobuf2-core as a module, the vb2_* tracepoints must be exported from the videodev module. Instead of exporting vb2 tracepoint symbols from v4l2-ioctl.c, move the tracepoint generation into a separate file. This patch fixes the following build error in the modpost stage, introduced by 2091f5181c66 ("[media] videobuf2: add trace events"): ERROR: "__tracepoint_vb2_buf_done" undefined! ERROR: "__tracepoint_vb2_dqbuf" undefined! ERROR: "__tracepoint_vb2_qbuf" undefined! ERROR: "__tracepoint_vb2_buf_queue" undefined! Suggested-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] vivid: support cvt, gtf timings for video outPrashant Laddha
The generation of cvt, gtf timings is already supported by v4l2-ctl. This patch adds support for setting cvt,gtf timings for video out. While enabling cvt,gtf in vivid capture, the vivid video out was missed out. Adding it now. Signed-off-by: Prashant Laddha <prladdha@cisco.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] media: adv7604: reduce support to first (digital) inputWilliam Towle
Using adv7611_read_cable_det() for ADV7612 means that full support for '.max_port = ADV7604_PAD_HDMI_PORT_B,' isn't available due to the need for multiple port reads to determine cable detection, and an agreed mechanism for communicating the separate statuses. This patch replaces adv7611_read_cable_det() with a functionally identical copy, commented appropriately. Earlier submissions [leading to commit 8331d30b] also set .cp_csc, which is used in a cp_read() call within adv76xx_log_status(). Signed-off-by: William Towle <william.towle@codethink.co.uk> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] media: adv7604: fix probe of ADV7611/7612William Towle
Prior to commit f862f57d ("[media] media: i2c: ADV7604: Migrate to regmap"), the local variable 'val' contained the combined register reads used in the chipset version ID test. Restore this expectation so that the comparison works as it used to. Signed-off-by: William Towle <william.towle@codethink.co.uk> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] soc_camera: always release queue for queue ownerHans Verkuil
Always release the queue if the owner closes its filehandle and not when it is the last open filehandle. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] soc_camera: pass on streamoff errorHans Verkuil
If streamoff returned an error, then pass that on to the caller. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] soc_camera: compliance fixesHans Verkuil
- REQBUFS(0) will stop streaming, free buffers and release the file ownership. - Return ENOTTY for create_bufs for a vb1 driver - Return EBUSY if there is a different streaming owner and set the new owner on success. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] soc_camera: fix expbuf supportHans Verkuil
- For vb1 drivers just return -ENOTTY. - For vb2 drivers allow vb2_expbuf without there being a stream owner: the vb2_expbuf function will return the correct error message in that case. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] soc_camera: fix enum_inputHans Verkuil
Fill in the std field from the video_device tvnorms field. This fixes a v4l2-compliance failure. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Rob Taylor <rob.taylor@codethink.co.uk> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] sh_mobile_ceu_camera: set field to FIELD_NONEHans Verkuil
Make sure that 'field' isn't FIELD_ANY when the driver is first loaded. Fixes a v4l2-compliance failure. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] sh_mobile_ceu_camera: fix querycapHans Verkuil
Fill in the bus_info and driver fields. Found by v4l2-compliance. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] mt9t112: JPEG -> SRGBHans Verkuil
The JPEG colorspace should only be used for JPEG encoded images. This is just a regular sRGB sensor. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] ak881x: simplify standard checksHans Verkuil
Simplify confusing conditions. This also swaps the checks for NTSC and PAL: to be consistent with other drivers check for NTSC first. So if the user sets both NTSC and PAL bits, then NTSC wins. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] tw9910: init priv->scale and update standardHans Verkuil
When the standard changes the VACTIVE and VDELAY values need to be updated. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] tw9910: don't use COLORSPACE_JPEGHans Verkuil
This is an SDTV video receiver, so the colorspace should be SMPTE170M. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] sh-veu: initialize timestamp_flags and copy timestamp infoHans Verkuil
This field wasn't set, causing WARN_ON's from the vb2 core. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
2015-08-11[media] tda10071: implement DVBv5 statisticsAntti Palosaari
Implement DVBv5 CNR, signal strength, BER and block errors. Wrap legacy DVBv3 statistics to DVBv5 internally. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>