Jan Kara [Mon, 13 Jul 2015 14:55:50 +0000 (11:55 -0300)]
[media] media: vb2: Remove unused functions
Conversion to the use of pinned pfns made some functions unused. Remove
them. Also there's no need to lock mmap_sem in __buf_prepare() anymore.
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:49 +0000 (11:55 -0300)]
[media] media: vb2: Convert vb2_dc_get_userptr() to use frame vector
Convert vb2_dc_get_userptr() to use frame vector infrastructure. When we
are doing that there's no need to allocate page array and some code can
be simplified.
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:48 +0000 (11:55 -0300)]
[media] media: vb2: Convert vb2_vmalloc_get_userptr() to use frame vector
Convert vb2_vmalloc_get_userptr() to use frame vector infrastructure.
When we are doing that there's no need to allocate page array and some
code can be simplified.
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:47 +0000 (11:55 -0300)]
[media] media: vb2: Convert vb2_dma_sg_get_userptr() to use frame vector
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:46 +0000 (11:55 -0300)]
[media] vb2: Provide helpers for mapping virtual addresses
Provide simple helper functions to map virtual address range into an
array of pfns / pages.
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:45 +0000 (11:55 -0300)]
[media] media: omap_vout: Convert omap_vout_uservirt_to_phys() to use get_vaddr_pfns()
Convert omap_vout_uservirt_to_phys() to use get_vaddr_pfns() instead of
hand made mapping of virtual address to physical address. Also the
function leaked page reference from get_user_pages() so fix that by
properly release the reference when omap_vout_buffer_release() is
called.
Signed-off-by: Jan Kara <jack@suse.cz>
[hans.verkuil@cisco.com: remove unused variable] Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:44 +0000 (11:55 -0300)]
[media] mm: Provide new get_vaddr_frames() helper
Provide new function get_vaddr_frames(). This function maps virtual
addresses from given start and fills given array with page frame numbers of
the corresponding pages. If given start belongs to a normal vma, the function
grabs reference to each of the pages to pin them in memory. If start
belongs to VM_IO | VM_PFNMAP vma, we don't touch page structures. Caller
must make sure pfns aren't reused for anything else while he is using
them.
This function is created for various drivers to simplify handling of
their buffers.
Signed-off-by: Jan Kara <jack@suse.cz> Acked-by: Mel Gorman <mgorman@suse.de> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Jan Kara [Mon, 13 Jul 2015 14:55:43 +0000 (11:55 -0300)]
[media] vb2: Push mmap_sem down to memops
Currently vb2 core acquires mmap_sem just around call to
__qbuf_userptr(). However since commit f035eb4e976ef5 (videobuf2: fix
lockdep warning) it isn't necessary to acquire it so early as we no
longer have to drop queue mutex before acquiring mmap_sem. So push
acquisition of mmap_sem down into .get_userptr memop so that the
semaphore is acquired for a shorter time and it is clearer what it is
needed for.
Note that we also need mmap_sem in .put_userptr memop since that ends up
calling vb2_put_vma() which calls vma->vm_ops->close() which should be
called with mmap_sem held. However we didn't hold mmap_sem in some code
paths anyway (e.g. when called via vb2_ioctl_reqbufs() ->
__vb2_queue_free() -> vb2_dma_sg_put_userptr()) and getting mmap_sem in
put_userptr() introduces a lock inversion with queue->mmap_lock in the
above mentioned call path.
Luckily this whole locking mess will get resolved once we convert
videobuf2 core to the new mm helper which avoids the need for mmap_sem
in .put_userptr memop altogether.
Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
This got reported by smatch:
drivers/media/i2c/sr030pc30.c:505 sr030pc30_get_fmt() error: we previously assumed 'info->curr_win' could be null (see line 499)
drivers/media/i2c/sr030pc30.c:507 sr030pc30_get_fmt() error: we previously assumed 'info->curr_fmt' could be null (see line 499)
Why to store the chosed values for prediv, postdiv and mult if
those won't be used?
drivers/media/i2c/ov2659.c: In function 'ov2659_pll_calc_params':
drivers/media/i2c/ov2659.c:912:35: warning: variable 's_mult' set but not used [-Wunused-but-set-variable]
u32 s_prediv = 1, s_postdiv = 1, s_mult = 1;
^
drivers/media/i2c/ov2659.c:912:20: warning: variable 's_postdiv' set but not used [-Wunused-but-set-variable]
u32 s_prediv = 1, s_postdiv = 1, s_mult = 1;
^
drivers/media/i2c/ov2659.c:912:6: warning: variable 's_prediv' set but not used [-Wunused-but-set-variable]
u32 s_prediv = 1, s_postdiv = 1, s_mult = 1;
^
This is likely some leftover from some past change.
drivers/media/platform/sti/c8sectpfe/c8sectpfe-core.c:540:8: error: implicit declaration of function ‘pinctrl_select_state’ [-Werror=implicit-function-declaration]
ret = pinctrl_select_state(fei->pinctrl, tsin->pstate);
That's due the need of including pinctrl.h header and because
CONFIG_PINCTRL needs to be true.
Zahari Doychev [Mon, 3 Aug 2015 11:57:19 +0000 (08:57 -0300)]
[media] coda: drop zero payload bitstream buffers
The buffers with zero payload are now dumped in coda_fill_bitstream and not
passed to coda_bitstream_queue. This avoids unnecessary fifo addition and
buffer sequence counter increment.
[media] staging: media: lirc: Export I2C module alias information
The I2C core always reports the MODALIAS uevent as "i2c:<client name"
regardless if the driver was matched using the I2C id_table or the
of_match_table. So the driver needs to export the I2C table and this
be built into the module or udev won't have the necessary information
to auto load the correct module when the device is added.
Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
[media] Export I2C module alias information in missing drivers
The I2C core always reports the MODALIAS uevent as "i2c:<client name"
regardless if the driver was matched using the I2C id_table or the
of_match_table. So the driver needs to export the I2C table and this
be built into the module or udev won't have the necessary information
to auto load the correct module when the device is added.
Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:09:00 +0000 (14:09 -0300)]
[media] c8sectpfe: Add Kconfig and Makefile for the driver
This patch adds the Kconfig and Makefile for the c8sectpfe driver
so it will be built. It also selects additional demodulator and tuners
which are required by the supported NIM cards.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:59 +0000 (14:08 -0300)]
[media] c8sectpfe: Add c8sectpfe debugfs support
Some basic debugfs support to dump the IP registers. Further
statistics could easily be added in the future for example for
each enabled tsin channel we could expose number of corrupt packets
received etc.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:58 +0000 (14:08 -0300)]
[media] c8sectpfe: Add support for various ST NIM cards
This patch adds support for the following 2 NIM cards: -
1) B2100A (2x stv0367 demods & 2x NXP tda18212 tuners)
2) STV0903-6110NIM (stv0903 demod + 6110 tuner, lnb24)
A NIM card is a cold plugable expansion card which usually
features a demodulator / tuner combination.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:57 +0000 (14:08 -0300)]
[media] c8sectpfe: Add LDVB helper functions
These functions are used by the core code for creating the LDVB
devices and adapter.
Addtionally some older SoC's (and potentially newer ones) have different
frontend HW which would allow those devices to be easily supported
in the future by keeping the code specific to the IP separate from the
more generic code.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:56 +0000 (14:08 -0300)]
[media] c8sectpfe: STiH407/10 Linux DVB demux support
This patch adds support for the c8sectpfe input HW found on
STiH407/410 SoC's.
It currently supports the TS input block, memdma engine
and hw PID filtering blocks of the C8SECTPFE subsystem.
The driver creates one LinuxDVB adapter, and a
demux/dvr/frontend set of devices for each tsin channel
which is specificed in the DT. It has been tested with
multiple tsin channels tuned, locked, and grabbing TS
simultaneously.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Joe Perches [Thu, 30 Jul 2015 17:08:53 +0000 (14:08 -0300)]
[media] dvb-pll: Convert struct dvb_pll_desc uses to const
Convert the struct dvb_pll_desc uses to const and
change the "entries" fixed array size from 12 to []
It saves a couple KB overall and remove ~5KB of data.
$ size drivers/media/dvb-frontends/dvb-pll.o*
text data bss dec hex filename
8520 1552 2120 12192 2fa0 drivers/media/dvb-frontends/dvb-pll.o.new
5624 6363 2120 14107 371b drivers/media/dvb-frontends/dvb-pll.o.old
[PG] Patch taken from https://lkml.org/lkml/2015/6/24/721 with
commit message updated.
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Reviewed-by: Michael Ira Krufky <m.krufky@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:52 +0000 (14:08 -0300)]
[media] stv0367: Add support for 16Mhz reference clock
The B2100A dvb NIM card from ST has 2x stv0367 demodulators
and 2x TDA18212 silicon tuners, with a 16Mhz crystal. To
get this working properly with the upstream driver we need
to add support for the 16Mhz reference clock.
Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Peter Griffin [Thu, 30 Jul 2015 17:08:51 +0000 (14:08 -0300)]
[media] stv0367: Refine i2c error trace to include i2c address
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>
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.
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.
[media] cxd2841er: don't use variable length arrays
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.
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
[media] cxd2841er: declare static functions as such
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)
^
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>
Christian Löpke [Sat, 18 Jul 2015 07:15:01 +0000 (04:15 -0300)]
[media] Technisat SkyStar USB HD,(DVB-S/S2) too much URBs for arm devices
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>
David Härdeman [Wed, 22 Jul 2015 20:55:24 +0000 (17:55 -0300)]
[media] rc-core: improve the lirc protocol reporting
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>
Vaishali Thakkar [Fri, 26 Jun 2015 04:34:37 +0000 (01:34 -0300)]
[media] pctv452e: Replace memset with eth_zero_addr
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:
[media] tuners: Make all TV tuners visible if COMPILE_TEST=y
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.
Vaishali Thakkar [Fri, 26 Jun 2015 04:47:49 +0000 (01:47 -0300)]
[media] ttpci: Replace memset with eth_zero_addr
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:
[media] i2c: Make all i2c devices visible if COMPILE_TEST=y
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.
[media] dvb-frontends: Make all DVB Frontends visible if COMPILE_TEST=y
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.
[media] x86/mm/pat, drivers/media/ivtv: move pat warn and replace WARN() 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>
Antonio Borneo [Tue, 23 Jun 2015 14:53:19 +0000 (11:53 -0300)]
[media] s5c73m3: Remove redundant spi driver bus initialization
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>
Krzysztof Hałasa [Fri, 19 Jun 2015 10:20:40 +0000 (07:20 -0300)]
[media] pci/Kconfig: don't use MEDIA_ANALOG_TV_SUPPORT for grabber cards
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>
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>
Philipp Zabel [Thu, 6 Aug 2015 12:38:02 +0000 (09:38 -0300)]
[media] v4l2: move tracepoint generation into separate file
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"):
Prashant Laddha [Mon, 3 Aug 2015 08:36:43 +0000 (05:36 -0300)]
[media] vivid: support cvt, gtf timings for video out
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.
William Towle [Thu, 23 Jul 2015 12:21:34 +0000 (09:21 -0300)]
[media] media: adv7604: reduce support to first (digital) input
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>
William Towle [Thu, 23 Jul 2015 12:21:33 +0000 (09:21 -0300)]
[media] media: adv7604: fix probe of ADV7611/7612
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>
Hans Verkuil [Mon, 15 Jun 2015 11:33:38 +0000 (08:33 -0300)]
[media] soc_camera: compliance fixes
- 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.
Hans Verkuil [Mon, 15 Jun 2015 11:33:37 +0000 (08:33 -0300)]
[media] soc_camera: fix expbuf support
- 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.
Hans Verkuil [Mon, 15 Jun 2015 11:33:32 +0000 (08:33 -0300)]
[media] ak881x: simplify standard checks
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.
Antti Palosaari [Tue, 21 Apr 2015 14:16:44 +0000 (11:16 -0300)]
[media] tda10071: do not get_frontend() when not ready
This is a bit hack, but returning error when driver is not tuned yet
causes DVBv5 zap stop polling DVBv5 statistics. Thus return 0 even
callback is called during invalid device state.
Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Antti Palosaari [Tue, 21 Apr 2015 12:58:15 +0000 (09:58 -0300)]
[media] tda10071: protect firmware command exec with mutex
There should be clearly some lock in order to make sure firmware
command in execution is not disturbed by another command. It has
worked as callbacks are serialized somehow pretty well and command
execution happens usually without any delays.
Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
On power-on LNB power supply voltage is disabled, due to that no
need to disable it during probe. Tone is supply is hard-coded as
external tone coming from the demodulator. Program both voltage
and tone on set_voltage(). Use register cache to prevent unneeded
programming.
Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Hans Verkuil [Mon, 20 Jul 2015 13:18:22 +0000 (10:18 -0300)]
[media] bt819/saa7110/vpx3220: remove legacy control ops
The zoran driver has now been converted to the control framework
which means that these three subdevice drivers no longer need to
support the legacy core control ops since the last bridge driver
that needed that has now been converted.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Hans Verkuil [Mon, 20 Jul 2015 13:09:32 +0000 (10:09 -0300)]
[media] fsl-viu: small fixes
- Fix an off-by-one index check in vidioc_enum_fmt()
- Fill in the pix.sizeimage field in vidioc_try_fmt_cap()
- Fix an off-by-one index check in vidioc_s_input()
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>