Laurent Pinchart [Wed, 26 Sep 2012 08:54:17 +0000 (05:54 -0300)]
[media] mt9m032: Define MT9M032_READ_MODE1 bits
Replace hardcoded values with #define's.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Laurent Pinchart [Tue, 25 Sep 2012 13:46:34 +0000 (10:46 -0300)]
[media] mt9m032: Fix PLL setup
The MT9M032 PLL was assumed to be identical to the MT9P031 PLL but
differs significantly. Update the registers definitions and PLL limits
according to the datasheet.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 10 Apr 2013 09:42:44 +0000 (06:42 -0300)]
[media] exynos4-is: Disable debug trace by default in fimc-isp.c
Make sure the debug level is properly set initially so any debug
information is not printed to the kernel log without explicitly
enabling it.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 10 Apr 2013 09:27:22 +0000 (06:27 -0300)]
[media] exynos4-is: Remove meaningless test before bit setting
There is no need to check same bit before setting it, since we
always end up with a bit set. Remove some of the tests and make
set unconditional, in every place where all that needs to be done
is just setting a bit.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 10 Apr 2013 09:24:46 +0000 (06:24 -0300)]
[media] exynos4-is: Rename the ISP chain configuration data structure
More appropriate names for the ISP chain data structure.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 10 Apr 2013 09:23:05 +0000 (06:23 -0300)]
[media] exynos4-is: Improve the ISP chain parameter count calculation
Instead of incrementing p_region_num field each time we set a bit
in the parameter mask calculate the number of bits set only when
this information is needed.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 9 Apr 2013 14:11:58 +0000 (11:11 -0300)]
[media] exynos4-is: Make fimc-lite independent of struct fimc_sensor_info
Make the sensor subdevs host_data hold a pointer to struct fimc_source_info,
which is defined in the driver's public header, rather than a pointer to
struct fimc_sensor_info which is specific to exynos4-is media device driver.
The purpose of this change is to allow easier reuse of the fimc-lite module
in the exynos5-is driver, which should similarly store a pointer to struct
fimc_source_info instance in the sensor's subdev host_data.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 8 Apr 2013 16:17:36 +0000 (13:17 -0300)]
[media] exynos4-is: Make fimc-lite independent of the pipeline->subdevs array
Get the sensor subdev by walking media graph in both cases: when the
device is used as a subdev only and through video node. This allows
to not dereference the pipeline->subdevs[] array and makes the module
more generic and easier to re-use in other media driver.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 9 Apr 2013 10:19:27 +0000 (07:19 -0300)]
[media] exynos4-is: Move the subdev group ID definitions to public header
Move the sub-device group ID definitions to the driver's public header
so they are available to other media drivers that need to share modules
found in exynos4-is.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 10 Apr 2013 10:17:52 +0000 (07:17 -0300)]
[media] s5p-mfc: Remove potential uninitialized variable usage
Make sure mem_info[] array is not used uninitialized. This prevents
following compiler warning:
drivers/media/platform/s5p-mfc/s5p_mfc.c: In function s5p_mfc_probe:
drivers/media/platform/s5p-mfc/s5p_mfc.c:1032:33: warning: mem_info[0] may be used uninitialized in this function [-Wuninitialized]
drivers/media/platform/s5p-mfc/s5p_mfc.c:1021:15: note: mem_info[0] was declared here
drivers/media/platform/s5p-mfc/s5p_mfc.c:1032:33: warning: mem_info[1] may be used uninitialized in this function [-Wuninitialized]
drivers/media/platform/s5p-mfc/s5p_mfc.c:1021:15: note: mem_info[1] was declared here
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Hans Verkuil [Mon, 8 Apr 2013 08:10:34 +0000 (05:10 -0300)]
[media] s5c73m3: Fix s5c73m3-core.c compiler warning
Fix for this compiler warning:
CC [M] drivers/media/i2c/s5c73m3/s5c73m3-core.o
drivers/media/i2c/s5c73m3/s5c73m3-core.c: In function ‘s5c73m3_load_fw’:
drivers/media/i2c/s5c73m3/s5c73m3-core.c:360:2: warning: format ‘%d’ expects
argument of type ‘int’, but argument 4 has type ‘size_t’ [-Wformat]
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Kamil Debski [Fri, 11 Jan 2013 15:29:33 +0000 (12:29 -0300)]
[media] s5p-mfc: Add support for EOS command and EOS event in video decoder
Add support for V4L2_DEC_CMD_STOP command which will instruct MFC device
to finish decoding and release all remaining frames kept for reference to
the user. After dequeueing last decoded frame the driver will generate an
V4L2_EVENT_EOS event.
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Kyngmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Peter Wiese [Thu, 4 Apr 2013 20:36:12 +0000 (17:36 -0300)]
[media] budget: Add support for Philips Semi Sylt PCI ref. design
Add support for Philips Semiconductor (now NXP) SAA7146
reference design DVB Sat card, using ALPS BSRU6 tuner.
[mchehab@redhat.com: Merge conflicts fix; email whitespacing unmangling]
Signed-off-by: Peter Wiese <peter.wiese@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Evgeny Plehov [Mon, 8 Apr 2013 02:56:46 +0000 (23:56 -0300)]
[media] cxd2820r_t2: Multistream support (MultiPLP)
MultiPLP filtering support for CXD2820r.
Signed-off-by: Evgeny Plehov <EvgenyPlehov@ukr.net>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Mon, 8 Apr 2013 00:11:53 +0000 (21:11 -0300)]
[media] cx24123: improve precision when calculating symbol rate ratio
Symbol rate ratio were using a rough calculus, as the code was
limited to 32 bits arithmetic. Change it to 64 bits, in order
to better estimate the bandwidth low-pass filter on the demod.
This should reduce the noise and improve reception.
Reported-by: Hans-Peter Jansen <hpj@urpla.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Mon, 8 Apr 2013 00:07:47 +0000 (21:07 -0300)]
[media] mb86a20s: better name temp vars at mb86a20s_layer_bitrate()
Using 'i' for the guard interval temporary var is a bad idea, as
'i' is generally used by "anonymous" indexes.
Let's rename modulation, fec and guard interval temp vars with
a meaningful name, as that makes easier to understand the code
and avoids cut-and-paste types of error.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Mon, 8 Apr 2013 00:06:12 +0000 (21:06 -0300)]
[media] mb86a20s: Fix estimate_rate setting
As reported by Dan Carpenter <dan.carpenter@oracle.com>:
Smatch warnings:
drivers/media/dvb-frontends/mb86a20s.c:644 mb86a20s_layer_bitrate() error: buffer overflow 'state->estimated_rate' 3 <= 3
What happens there is that estimate_rate index should be the layer
number, and not the guard interval.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Sun, 7 Apr 2013 23:52:16 +0000 (20:52 -0300)]
[media] mb86a20s: Use 'layer' instead of 'i' on all places
We're using the anonymous 'i' to indicate the layer number
on several places on the driver. That's not good, as some
cut-and-paste type of change might be doing the wrong thing.
So, call it as "layer" everywhere.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Sun, 7 Apr 2013 23:51:32 +0000 (20:51 -0300)]
[media] mb86a20s: fix audio sub-channel check
As reported by Dan Carpenter <dan.carpenter@oracle.com>
FYI, there are new smatch warnings show up in:
tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next master
head:
da17d7bda957ae4697b6abc0793f74fb9b50b58f
commit:
04fa725e7b1c22c583dd71a8cd85b8d997edfce3 [media] mb86a20s: Implement set_frontend cache logic
New smatch warnings:
drivers/media/dvb-frontends/mb86a20s.c:1897 mb86a20s_set_frontend() error: buffer overflow 'mb86a20s_subchannel' 8 <= 8
04fa725e Mauro Carvalho Chehab 2013-03-04 1894 if (c->isdbt_sb_subchannel > ARRAY_SIZE(mb86a20s_subchannel))
04fa725e Mauro Carvalho Chehab 2013-03-04 1895 c->isdbt_sb_subchannel = 0;
04fa725e Mauro Carvalho Chehab 2013-03-04 1896
04fa725e Mauro Carvalho Chehab 2013-03-04 @1897 state->subchannel = mb86a20s_subchannel[c->isdbt_sb_subchannel];
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Sun, 7 Apr 2013 23:50:34 +0000 (20:50 -0300)]
[media] mb86a20s: Use a macro for the number of layers
Instead of using the magic number "3", use NUM_LAYERS macro
on all places that are related to the ISDB-T layers.
This makes the source code a little more readable.
No functional changes.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Ondrej Zary [Sat, 6 Apr 2013 17:29:29 +0000 (14:29 -0300)]
[media] tda8290: change magic LNA config values to enum
Use enum instead of magic values for LNA config in tda8290.
Update tda827x, tda18271 and saa7134 to use the enum too.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Ondrej Zary [Sat, 6 Apr 2013 17:28:16 +0000 (14:28 -0300)]
[media] saa7134: Add AverMedia A706 AverTV Satellite Hybrid+FM
Add AverMedia AverTV Satellite Hybrid+FM (A706) card to saa7134 driver.
Working: analog inputs, TV, FM radio and IR remote control.
Untested: DVB-S.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Ondrej Zary [Sat, 6 Apr 2013 17:21:36 +0000 (14:21 -0300)]
[media] tuner-core: Change config from unsigned int to void *
config looks like a hack that was added to tuner-core to allow some
configuration of TDA8290 tuner (it's not used by any other driver).
But with the new configuration options of tda8290 driver (no_i2c_gate
and std_map), it's no longer sufficient.
Change config to be void * instead, which allows passing tuner-dependent
config struct to drivers.
Also update saa7134 driver to reflect this change (no other driver uses this).
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Ondrej Zary [Mon, 4 Feb 2013 01:48:56 +0000 (22:48 -0300)]
[media] tda8290: Allow custom std_map for tda18271
Allow specifying a custom std_map for tda18271 by external configuration.
This is required by cards that require custom std_map for analog TV or radio,
like AverMedia A706.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Ondrej Zary [Mon, 4 Feb 2013 01:47:38 +0000 (22:47 -0300)]
[media] tda8290: Allow disabling I2C gate
Allow disabling I2C gate handling by external configuration.
This is required by cards that have all devices on a single I2C bus,
like AverMedia A706.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Fri, 5 Apr 2013 15:18:54 +0000 (12:18 -0300)]
[media] cx88: kernel bz#9476: Fix tone setting for Nova-S+ model 92001
Hauppauge Nova-S-Plus DVB-S model 92001 does not lock on horizontal
polarisation. According with the info provided at the BZ, model
92002 does.
The difference is that, on model 92001, the tone select is done via
isl6421, while, on other devices, this is done via cx24123 code.
This patch adds a way to override the demod's set_tone at isl6421
driver. In order to avoid regressions, the override is enabled
only for cx88 Nova S plus model 92001. For all other models and
devices, the set_tone is provided by the demod driver.
Patch originally proposed at bz@9476[1] by Michel Meyers and
John Donoghue but applying the original patch would break support
for all other devices based on isl6421.
[1] https://bugzilla.kernel.org/show_bug.cgi?id=9476
Tested-by: Adam Sampson <ats@offog.org>
Tested-by: Hans-Peter Jansen <hpj@urpla.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Jiri Slaby [Thu, 4 Apr 2013 19:32:09 +0000 (16:32 -0300)]
[media] MEDIA: ttusbir, fix double free
rc_unregister_device already calls rc_free_device to free the passed
device. But in one of ttusbir's probe fail paths, we call
rc_unregister_device _and_ rc_free_device. This is wrong and results
in a double free.
Instead, set rc to NULL resulting in rc_free_device being a noop.
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Thu, 4 Apr 2013 16:25:30 +0000 (13:25 -0300)]
[media] demux.h: Remove duplicated enum
"enum dmx_ts_pes" and "typedef enum dmx_pes_type_t" are just the
same enum declared twice, since Kernel (2.6.12). There's no reason
to duplicate it there, and sparse complains about that:
drivers/media/dvb-core/dmxdev.c:600:55: warning: mixing different enum types
So, remove the internal define, keeping just the external one.
Internally, use only "enum dmx_ts_pes", as it is too late to drop
dmx_pes_type_t from the userspace API.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 25 Mar 2013 19:50:50 +0000 (16:50 -0300)]
[media] exynos4-is: Ensure proper media pipeline state on device close
Make sure media_entity_pipeline_stop() is called on video device
close in cases where there was VIDIOC_STREAMON ioctl and no
VIDIOC_STREAMOFF. This patch fixes media entities stream_count
state which could prevent links from being disconnected, due to
non-zero stream_count.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Thu, 21 Mar 2013 17:22:34 +0000 (14:22 -0300)]
[media] exynos4-is: Correct input DMA YUV order configuration
This patch fixes erroneous setup of the YUV order caused by not
clearing FIMC_REG_MSCTRL_ORDER422_MASK bit field before setting
proper FIMC_REG_MSCTRL_ORDER422 bits. This resulted in false
colors for YUYV, YVYU, UYVY, VYUY color formats, depending in
what sequence those were configured by user space.
YUV order definitions are corrected so that following convention
is used:
| byte3 | byte2 | byte1 | byte0
-------+-------+-------+-------+------
YCBYCR | CR | Y | CB | Y
YCRYCB | CB | Y | CR | Y
CBYCRY | Y | CR | Y | CB
CRYCBY | Y | CB | Y | CR
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 20 Mar 2013 18:31:03 +0000 (15:31 -0300)]
[media] exynos4-is: Allow colorspace conversion at FIMC-LITE
The FIMC-LITE output DMA allows to configure different YUV order
than the order at the camera input interface. Thus there is some
limited colorspace conversion possible. This patch makes the
color format variable be per FIMC-LITE input/output, rather than
a global per device. This also fixes incorrect behavior where
color format at the FIMC-LITE.N subdev's source pad is modified
by VIDIOC_S_FMT ioctl on the related video node.
YUV order definitions are corrected so that we use notation:
| byte3 | byte2 | byte1 | byte0
-------+-------+-------+-------+------
YCBYCR | CR | Y | CB | Y
YCRYCB | CB | Y | CR | Y
CBYCRY | Y | CR | Y | CB
CRYCBY | Y | CB | Y | CR
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Sat, 16 Mar 2013 20:35:10 +0000 (17:35 -0300)]
[media] exynos4-is: Use common driver data for all FIMC-LITE IP instances
There is no need to use separate variant data structure for each
FIMC-LITE IP instance. According to my knowledge there are no
differences across them on Exynos4 as well as Exynos5 SoCs. Drop
flite_variant data structure and use struct flite_drvdata instead.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Sun, 24 Feb 2013 21:29:21 +0000 (18:29 -0300)]
[media] exynos4-is: Remove static driver data for Exynos4210 FIMC variants
The Exynos platform will support only device tree based booting
from v3.10. The FIMC variant data will be parsed directly from
the device tree, hence the now unused static data can be removed.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 27 Nov 2012 16:29:48 +0000 (13:29 -0300)]
[media] exynos4-is: Create media links for the FIMC-IS entities
Create disabled links from the FIMC-LITE subdevs to the FIMC-IS-ISP
subdev and from FIMC-IS-ISP to all FIMC subdevs.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Thu, 21 Mar 2013 17:49:16 +0000 (14:49 -0300)]
[media] exynos4-is: Add fimc-is subdevs registration
This patch adds support for registration of the FIMC-IS device
represented by the FIMC-IS-ISP subdev to the top level media device
driver. The FIMC-IS subsystem is available on Exynos4x12 SoCs which
support only device tree based booting.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 26 Mar 2013 12:21:23 +0000 (09:21 -0300)]
[media] exynos4-is: Add Exynos4x12 FIMC-IS device tree binding documentation
This patch adds DT binding documentaton for the Imaging Subsystem
(camera ISP) found on Samsung Exynos4x12 SoCs.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 11 Mar 2013 18:38:29 +0000 (15:38 -0300)]
[media] exynos4-is: Add common FIMC-IS image sensor driver
This patch adds a common image sensor driver and Makefile/Kconfig
to enable compilation of the whole IS driver.
The sensor subdev driver currently only handles an image sensor's
power supplies and reset signal. There is no I2C communication as
it is handled by the ISP's firmware.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 11 Mar 2013 18:33:56 +0000 (15:33 -0300)]
[media] exynos4-is: Add FIMC-IS parameter region definitions
This patch adds the ISP processing parameters interface files.
Signed-off-by: Younghwan Joo <yhwan.joo@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 11 Mar 2013 18:28:18 +0000 (15:28 -0300)]
[media] exynos4-is: Add FIMC-IS ISP I2C bus driver
This patch adds the ISP I2C bus controller driver files.
Creating a standard I2C bus adapter, even if the driver doesn't
actually communicate with the hardware and it is instead
controlled by the ISP firmware running on the Cortex-A5, allows
to use standard hardware description in the device tree. As the
sensor would have actually had a standard V4L2 sub-device driver
run on the host CPU.
This approach allows to adapt the driver with a relatively small
effort should the Imaging Subsystem architecture change so that
the I2C bus is handled by the host's CPU OS, rather than the
internal FIMC-IS ARM CPU firmware. The image sensor driver could
be a standard I2C client driver, as in case of most existing
image sensors.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 11 Mar 2013 18:14:58 +0000 (15:14 -0300)]
[media] exynos4-is: Add Exynos4x12 FIMC-IS driver
This patch adds a set of core files of the Exynos4x12 FIMC-IS
V4L2 driver. This includes main functionality like allocating
memory, loading the firmware, FIMC-IS register interface and
host CPU <-> IS command and error code definitions.
The driver currently exposes a single subdev named FIMC-IS-ISP,
which corresponds to the FIMC-IS ISP and DRC IP blocks.
The FIMC-IS-ISP subdev currently supports only a subset of user
controls. For other controls we need several extensions at the
V4L2 API. The supported standard controls are:
brightness, contrast, saturation, hue, sharpness, 3a_lock,
exposure_time_absolute, white_balance_auto_preset,
iso_sensitivity, iso_sensitivity_auto, exposure_metering_mode.
Signed-off-by: Younghwan Joo <yhwan.joo@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 2 Apr 2013 14:41:19 +0000 (11:41 -0300)]
[media] V4L: Remove incorrect EXPORT_SYMBOL() usage at v4l2-of.c
v4l2_of_parse_parallel_bus() function is now static and
EXPORT_SYMBOL() doesn't apply to it any more. Drop this
meaningless statement, which was supposed to be done in
the original merged patch.
While at it, edit the copyright notice so it is sorted in
both the v4l2-of.c and v4l2-of.h file in newest entries
on top order, and state clearly I'm just the author of
parts of the code, not the copyright owner.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 2 Apr 2013 09:45:59 +0000 (06:45 -0300)]
[media] exynos4-is: Correct clock properties description at the DT binding documentation
The 'camera' DT node needs to have sclk_cam0/1 and pxl_async0/1 clocks
specified, while 'fimc' nodes should have only "fimc" and "sclk_fimc".
"mux" and "parent" are leftovers from early versions of patches adding
DT support, when the IP bus clock parent clock was being set by the
driver. A better solution is needed to have e.g. clocks driver setting
all required parent clocks, before clock consumers start using the
clocks. Currently this binding doesn't describe parent clocks setup,
it needs to be specified and handled somewhere else.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Sun, 31 Mar 2013 23:31:02 +0000 (20:31 -0300)]
[media] exynos4-is: Remove dependency on SYSCON for non-dt platforms
Currently the whole driver depends on MFD_SYSCON, which in turn
depends on OF. To allow to use the driver on non-dt platforms
(S5PV210) the SYSREG support is made conditional (it is needed
only for dt enabled platforms) and MFD_SYSCON is selected if
OF is enabled, instead of depending on OF.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Arnd Bergmann [Tue, 5 Mar 2013 17:42:20 +0000 (14:42 -0300)]
[media] exynos: remove unnecessary header inclusions
In multiplatform configurations, we cannot include headers
provided by only the exynos platform. Fortunately a number
of drivers that include those headers do not actually need
them, so we can just remove the inclusions.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:41 +0000 (02:00 -0300)]
[media] soc_camera/soc_camera_platform: Fix warning related to spacing
Fixes the following checkpatch warning:
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:40 +0000 (02:00 -0300)]
[media] soc_camera/sh_mobile_ceu_camera: Fix warning related to spacing
Fixes the following checkpatch warning:
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:39 +0000 (02:00 -0300)]
[media] soc_camera/pxa_camera: Constify struct dev_pm_ops
struct dev_pm_ops should be const.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:38 +0000 (02:00 -0300)]
[media] soc_camera/pxa_camera: Fix warning related to spacing
Fixes the following checkpatch warning:
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:37 +0000 (02:00 -0300)]
[media] soc_camera/mx3_camera: Fix warning related to spacing
Silences the following checkpatch warning:
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:36 +0000 (02:00 -0300)]
[media] soc_camera/mx2_camera: Fix warnings related to spacing
Fixes the following checkpatch warnings:
WARNING: unnecessary whitespace before a quoted newline
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sachin Kamat [Wed, 3 Apr 2013 05:00:35 +0000 (02:00 -0300)]
[media] soc_camera/mx1_camera: Fix warnings related to spacing
Fixes the following checkpatch warnings:
WARNING: unnecessary whitespace before a quoted newline
WARNING: please, no space before tabs
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Tushar Behera [Fri, 16 Nov 2012 06:50:37 +0000 (03:50 -0300)]
[media] atmel-isi: Update error check for unsigned variables
Checking '< 0' for unsigned variables always returns false. For error
codes, use IS_ERR_VALUE() instead.
Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Phil Edworthy [Mon, 18 Mar 2013 11:47:59 +0000 (08:47 -0300)]
[media] soc_camera: Add RGB666 & RGB888 formats
Based on work done by Katsuya Matsubara.
Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Fabio Porcedda [Mon, 18 Mar 2013 09:43:56 +0000 (06:43 -0300)]
[media] mx2_camera: use module_platform_driver_probe()
The commit 39793c6 "[media] mx2_camera: Convert it to platform driver"
used module_platform_driver() to make code smaller,
but since the driver used platform_driver_probe is more appropriate
to use module_platform_driver_probe().
Signed-off-by: Fabio Porcedda <fabio.porcedda@gmail.com>
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Fabio Porcedda [Thu, 14 Mar 2013 17:09:31 +0000 (14:09 -0300)]
[media] drivers: media: use module_platform_driver_probe()
This patch converts the drivers to use the
module_platform_driver_probe() macro which makes the code smaller and
a bit simpler.
Signed-off-by: Fabio Porcedda <fabio.porcedda@gmail.com>
[g.liakhovetski@gmx.de: also remove redundant .probe initialisation]
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Guennadi Liakhovetski [Wed, 9 Jan 2013 12:14:48 +0000 (09:14 -0300)]
[media] soc-camera: protect against racing open(2) and rmmod
To protect against open() racing with rmmod, hold the list_lock also while
obtaining a reference to the camera host driver and check that the video
device hasn't been unregistered yet.
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Mon, 1 Apr 2013 14:46:52 +0000 (11:46 -0300)]
[media] siano: Fix array boundary at smscore_translate_msg()
As reported by Dan Carpenter:
FYI, there are new smatch warnings show up in
tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next master
head:
da17d7bda957ae4697b6abc0793f74fb9b50b58f
commit:
4c3bdb5e2f5612ceb99ac17dbbe673b59a94d105 [media] siano: better debug send/receive messages
drivers/media/common/siano/smscoreapi.c:396 smscore_translate_msg() error: buffer overflow 'siano_msgs' 401 <= 401
While it is almost impossible for this error to happen in
practice, as it would require the siano's firmware to return
an special invalid answer to a message request, fixing it
is trivial. So, let's do it.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Mauro Carvalho Chehab [Mon, 1 Apr 2013 12:54:14 +0000 (09:54 -0300)]
Merge tag 'v3.9-rc5' into patchwork
Linux 3.9-rc5
* tag 'v3.9-rc5': (1080 commits)
Linux 3.9-rc5
Revert "lockdep: check that no locks held at freeze time"
dw_dmac: adjust slave_id accordingly to request line base
dmaengine: dw_dma: fix endianess for DT xlate function
PNP: List Rafael Wysocki as a maintainer
rbd: don't zero-fill non-image object requests
ia64 idle: delete stale (*idle)() function pointer
Btrfs: don't drop path when printing out tree errors in scrub
target: Fix RESERVATION_CONFLICT status regression for iscsi-target special case
tcm_vhost: Avoid VIRTIO_RING_F_EVENT_IDX feature bit
Revert "mm: introduce VM_POPULATE flag to better deal with racy userspace programs"
usb: ftdi_sio: Add support for Mitsubishi FX-USB-AW/-BD
mg_disk: fix error return code in mg_probe()
Btrfs: fix wrong return value of btrfs_lookup_csum()
Btrfs: fix wrong reservation of csums
Btrfs: fix double free in the btrfs_qgroup_account_ref()
Btrfs: limit the global reserve to 512mb
Btrfs: hold the ordered operations mutex when waiting on ordered extents
Btrfs: fix space accounting for unlink and rename
Btrfs: fix space leak when we fail to reserve metadata space
...
Linus Torvalds [Sun, 31 Mar 2013 22:12:43 +0000 (15:12 -0700)]
Linux 3.9-rc5
Linus Torvalds [Sun, 31 Mar 2013 18:41:47 +0000 (11:41 -0700)]
Merge branch 'fixes' of git://git.infradead.org/users/vkoul/slave-dma
Pull slave-dmaengine fixes from Vinod Koul:
"Two fixes for slave-dmaengine.
The first one is for making slave_id value correct for dw_dmac and
the other one fixes the endieness in DT parsing"
* 'fixes' of git://git.infradead.org/users/vkoul/slave-dma:
dw_dmac: adjust slave_id accordingly to request line base
dmaengine: dw_dma: fix endianess for DT xlate function
Linus Torvalds [Sun, 31 Mar 2013 18:40:33 +0000 (11:40 -0700)]
Merge branch 'v4l_for_linus' of git://git./linux/kernel/git/mchehab/linux-media
Pull media fixes from Mauro Carvalho Chehab:
"For a some fixes for Kernel 3.9:
- subsystem build fix when VIDEO_DEV=y, VIDEO_V4L2=m and I2C=m
- compilation fix for arm multiarch preventing IR_RX51 to be selected
- regression fix at bttv crop logic
- s5p-mfc/m5mols/exynos: a few fixes for cameras on exynos hardware"
* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
[media] [REGRESSION] bt8xx: Fix too large height in cropcap
[media] fix compilation with both V4L2 and I2C as 'm'
[media] m5mols: Fix bug in stream on handler
[media] s5p-fimc: Do not attempt to disable not enabled media pipeline
[media] s5p-mfc: Fix encoder control 15 issue
[media] s5p-mfc: Fix frame skip bug
[media] s5p-fimc: send valid m2m ctx to fimc_m2m_job_finish
[media] exynos-gsc: send valid m2m ctx to gsc_m2m_job_finish
[media] fimc-lite: Fix the variable type to avoid possible crash
[media] fimc-lite: Initialize 'step' field in fimc_lite_ctrl structure
[media] ir: IR_RX51 only works on OMAP2
Linus Torvalds [Sun, 31 Mar 2013 18:38:59 +0000 (11:38 -0700)]
Merge tag 'for-linus-
20130331' of git://git.kernel.dk/linux-block
Pull block fixes from Jens Axboe:
"Alright, this time from 10K up in the air.
Collection of fixes that have been queued up since the merge window
opened, hence postponed until later in the cycle. The pull request
contains:
- A bunch of fixes for the xen blk front/back driver.
- A round of fixes for the new IBM RamSan driver, fixing various
nasty issues.
- Fixes for multiple drives from Wei Yongjun, bad handling of return
values and wrong pointer math.
- A fix for loop properly killing partitions when being detached."
* tag 'for-linus-
20130331' of git://git.kernel.dk/linux-block: (25 commits)
mg_disk: fix error return code in mg_probe()
rsxx: remove unused variable
rsxx: enable error return of rsxx_eeh_save_issued_dmas()
block: removes dynamic allocation on stack
Block: blk-flush: Fixed indent code style
cciss: fix invalid use of sizeof in cciss_find_cfgtables()
loop: cleanup partitions when detaching loop device
loop: fix error return code in loop_add()
mtip32xx: fix error return code in mtip_pci_probe()
xen-blkfront: remove frame list from blk_shadow
xen-blkfront: pre-allocate pages for requests
xen-blkback: don't store dev_bus_addr
xen-blkfront: switch from llist to list
xen-blkback: fix foreach_grant_safe to handle empty lists
xen-blkfront: replace kmalloc and then memcpy with kmemdup
xen-blkback: fix dispatch_rw_block_io() error path
rsxx: fix missing unlock on error return in rsxx_eeh_remap_dmas()
Adding in EEH support to the IBM FlashSystem 70/80 device driver
block: IBM RamSan 70/80 error message bug fix.
block: IBM RamSan 70/80 branding changes.
...
Paul Walmsley [Sun, 31 Mar 2013 00:04:40 +0000 (00:04 +0000)]
Revert "lockdep: check that no locks held at freeze time"
This reverts commit
6aa9707099c4b25700940eb3d016f16c4434360d.
Commit
6aa9707099c4 ("lockdep: check that no locks held at freeze time")
causes problems with NFS root filesystems. The failures were noticed on
OMAP2 and 3 boards during kernel init:
[ BUG: swapper/0/1 still has locks held! ]
3.9.0-rc3-00344-ga937536 #1 Not tainted
-------------------------------------
1 lock held by swapper/0/1:
#0: (&type->s_umount_key#13/1){+.+.+.}, at: [<
c011e84c>] sget+0x248/0x574
stack backtrace:
rpc_wait_bit_killable
__wait_on_bit
out_of_line_wait_on_bit
__rpc_execute
rpc_run_task
rpc_call_sync
nfs_proc_get_root
nfs_get_root
nfs_fs_mount_common
nfs_try_mount
nfs_fs_mount
mount_fs
vfs_kern_mount
do_mount
sys_mount
do_mount_root
mount_root
prepare_namespace
kernel_init_freeable
kernel_init
Although the rootfs mounts, the system is unstable. Here's a transcript
from a PM test:
http://www.pwsan.com/omap/testlogs/test_v3.9-rc3/
20130317194234/pm/37xxevm/37xxevm_log.txt
Here's what the test log should look like:
http://www.pwsan.com/omap/testlogs/test_v3.8/
20130218214403/pm/37xxevm/37xxevm_log.txt
Mailing list discussion is here:
http://lkml.org/lkml/2013/3/4/221
Deal with this for v3.9 by reverting the problem commit, until folks can
figure out the right long-term course of action.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Mandeep Singh Baines <msb@chromium.org>
Cc: Jeff Layton <jlayton@redhat.com>
Cc: Shawn Guo <shawn.guo@linaro.org>
Cc: <maciej.rutecki@gmail.com>
Cc: Fengguang Wu <fengguang.wu@intel.com>
Cc: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Ben Chan <benchan@chromium.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Rafael J. Wysocki <rjw@sisk.pl>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Hans Verkuil [Fri, 29 Mar 2013 20:22:24 +0000 (17:22 -0300)]
[media] si476x: Fix some config dependencies and a compile warnings
radio-si476x depends on SND and SND_SOC, the mfd driver should select
REGMAP_I2C.
Also fix a small compile warning in a debug message:
drivers/mfd/si476x-i2c.c: In function ‘si476x_core_drain_rds_fifo’:
drivers/mfd/si476x-i2c.c:391:4: warning: field width specifier ‘*’ expects argument of type ‘int’, but argument 4 has type ‘long unsigned int’ [-Wformat]
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Jean Delvare [Sun, 31 Mar 2013 10:16:37 +0000 (07:16 -0300)]
[media] m920x: Fix uninitialized variable warning
drivers/media/usb/dvb-usb/m920x.c:91:6: warning: "ret" may be used uninitialized in this function [-Wuninitialized]
drivers/media/usb/dvb-usb/m920x.c:70:6: note: "ret" was declared here
This is real, if a remote control has an empty initialization sequence
we would get success or failure randomly.
OTOH the initialization of ret in m920x_init is needless, the function
returns with an error as soon as an error happens, so the last return
can only be a success and we can hard-code 0 there.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Hans Verkuil [Sat, 30 Mar 2013 08:31:42 +0000 (05:31 -0300)]
[media] em28xx: fix typo in scale_to_size()
em28xx: fix typo in scale_to_size().
The second hscale should be vscale. This bug caused xawtv to fail because it
cannot find a workable image size.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Frank Schäfer <fschaefer.oss@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Sun, 24 Mar 2013 15:54:25 +0000 (16:54 +0100)]
[media] s5p-fimc: Change the driver directory name to exynos4-is
The s5p-fimc directory now contains drivers for multiple IP blocks
found in multiple Samsung application processors. This includes FIMC
(CAMIF), MIPI CSIS and FIMC LITE. FIMC-IS (Imaging Subsystem) driver
is going to be put into same directory. Hence we rename it to
exynos4-is as s5p-fimc was only relevant for early version of this
driver, when it only supported FIMC IP block.
The imaging subsystem drivers for Exynos4 SoC series and S5PV210 will
be included in drivers/media/platform/exynos4-is directory, with some
modules shared with exynos5 series, while the rest of exynos5 specific
modules will find their home in drivers/media/platform/exynos5-is.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 25 Feb 2013 16:20:21 +0000 (13:20 -0300)]
[media] s5p-fimc: Remove dependency on fimc-core.h in fimc-lite driver
Drop fimc-lite.h header inclusion to make the exynos-fimc-lite
module independent on other modules. Move struct fimc_fmt
declaration to the driver's private headers as it is used in
multiple modules.
Reported-by: Shaik Ameer Basha <shaik.ameer@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 20 Nov 2012 11:54:22 +0000 (08:54 -0300)]
[media] s5p-fimc: Ensure proper s_power() call order in the ISP datapaths
Since the FIMC-IS firmware communicates with an image sensor directly
through the ISP I2C bus controllers the sub-devices power supplies
cannot be simply enabled from left to right or disabled from right
to left along the processing pipeline. Thus a subdev index to call
s_power() on is looked up from a table, rather than doing the op call
based on increasing/decreasing indexes.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 13 Nov 2012 17:35:22 +0000 (14:35 -0300)]
[media] s5p-fimc: Ensure proper s_stream() call order in the ISP datapaths
Since the FIMC-IS firmware communicates with an image sensor directly
through the ISP I2C bus controllers data streaming cannot be simply
enabled from left to right or disabled from right to left along the
processing pipeline. Thus a subdev index to call s_stream() on is
looked up from a table, rather than doing the op call based on
increasing/decreasing indexes.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Thu, 21 Mar 2013 17:47:17 +0000 (14:47 -0300)]
[media] s5p-fimc: Ensure CAMCLK clock can be enabled by FIMC-LITE devices
In configurations where FIMC-LITE is used to capture image signal
from an external sensor only we need to ensure one of FIMC devices
is in active power state and the "fimc" gate clock is enabled.
Otherwise the CAMCLK clock output signal will be masked off
preventing an external sensor's operation.
This affect processing pipelines like:
- sensor -> FIMC-LITE -> memory
- sensor -> MIPI-CSIS -> FIMC-LITE -> memory
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 20 Mar 2013 13:44:39 +0000 (10:44 -0300)]
[media] s5p-fimc: Add support for ISP Writeback data input bus type
A second sink pad is added to each FIMC.N subdev that will be used
to link it to the FIMC-IS-ISP subdev. Only V4L2_MBUS_FMT_YUV10_1X30
format is supported at this pad (FIMC_SD_PAD_SINK_FIFO).
The routine checking for mismatch in the image formats at sides of
the links is updated to account for the fact FIMC.X subdevs now have
sink pads at the pad indexes 0, 1 and source pad at pad index 2.
If link to FIMC.X pad 1 is activated we switch FIMC input data bus
type to the ISP Writeback. Only a single active link to FIMC.X pad 0
or 1 will be allowed at any time.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Thu, 21 Mar 2013 17:43:17 +0000 (14:43 -0300)]
[media] s5p-fimc: Add support for PIXELASYNCMx clocks
This patch ads handling of clocks for the CAMBLK subsystem which
is a glue logic for FIMC-IS or LCD controller and FIMC IP.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Fri, 8 Mar 2013 11:58:34 +0000 (08:58 -0300)]
[media] s5p-fimc: Update graph traversal for entities with multiple source pads
We cannot assume that the passed entity the fimc_pipeline_prepare()
function is supposed to start the media graph traversal from will
always have its sink pad at pad index 0. Find the starting media
entity's sink pad by iterating over its all pads and checking the
pad flags. This ensures proper handling of FIMC, FIMC-LITE and
FIMC-IS-ISP subdevs that have more than one sink and one source pad.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Andrzej Hajda [Wed, 27 Feb 2013 11:13:59 +0000 (08:13 -0300)]
[media] s5p-fimc: Add error checks for pipeline stream on callbacks
set_stream error for pipelines is logged or reported to user
space if possible.
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Thu, 14 Mar 2013 10:01:24 +0000 (07:01 -0300)]
[media] V4L: Add MATRIX option to V4L2_CID_EXPOSURE_METERING control
This patch adds a menu option to the V4L2_CID_EXPOSURE_METERING
control for multi-zone metering.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Fri, 8 Mar 2013 13:41:47 +0000 (10:41 -0300)]
[media] s5p-fimc: Use pinctrl API for camera ports configuration
Before the camera ports can be used the pinmux needs to be configured
properly. This patch adds a function to set the camera ports pinctrl
to a default state within the media driver's probe().
The camera port(s) are then configured for the video bus operation.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Fri, 29 Mar 2013 17:12:39 +0000 (14:12 -0300)]
[media] s5p-fimc: Add device tree based sensors registration
The sensor (I2C and/or SPI client) devices are instantiated by their
corresponding control bus drivers. Since the I2C client's master clock
is often provided by a video bus receiver (host interface) or other
than I2C/SPI controller device, the drivers of those client devices
are not accessing hardware in their driver's probe() callback. Instead,
after enabling clock, the host driver calls back into a sub-device
when it wants to activate them. This pattern is used by some in-tree
drivers and this patch also uses it for DT case. This patch is intended
as a first step for adding device tree support to the S5P/Exynos SoC
camera drivers. The second one is adding support for asynchronous
sub-devices registration and clock control from sub-device driver
level. The bindings shall not change when asynchronous probing support
is added.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Fri, 8 Mar 2013 15:59:33 +0000 (12:59 -0300)]
[media] s5p-fimc: Add device tree support for the media device driver
This patch adds changes required for the main camera media device
driver corresponding to the top level 'camera' device node.
The drivers of devices corresponding to child nodes of the 'camera'
node are looked up and and registered as sub-devices to the top
level driver. The main driver's probing is deferred if any of the
sub-device drivers is not yet initialized and ready.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 26 Mar 2013 12:33:54 +0000 (09:33 -0300)]
[media] s5p-fimc: Add device tree support for FIMC-LITE device driver
This patch adds the device tree support for FIMC-LITE device
driver. The bindings include compatible property for the Exynos5
SoC series, however the actual implementation for these SoCs will
be added in a separate patch.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 26 Mar 2013 11:22:21 +0000 (08:22 -0300)]
[media] s5p-fimc: Add device tree support for FIMC device driver
This patch adds device tree support for FIMC driver on S5PV210
and Exynos4 SoCs.
The FIMC IP block's features and quirks encoded statically in
the driver are now parsed from the device tree. Once all relevant
platforms are converted to device tree based booting the FIMC
variant data structures will all be removed from the driver.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Tue, 26 Mar 2013 11:20:30 +0000 (08:20 -0300)]
[media] s5p-csis: Add device tree support
This patch support for binding the driver to the MIPI-CSIS
devices instantiated from device tree and parsing the SoC
and board specific properties. The MIPI CSI-2 channel is
determined by the value of reg property placed in csis'
port subnode.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 25 Mar 2013 19:43:08 +0000 (16:43 -0300)]
[media] s5p-fimc: Use vb2 ioctl helpers in fimc-lite
Replace some ioctl, file and video buffer queue operation handlers
with the videobuf2 helpers. This allows to get rid of significant
amount of boilerplate.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Mon, 25 Mar 2013 19:36:35 +0000 (16:36 -0300)]
[media] s5p-fimc: Use vb2 ioctl/fop helpers in FIMC capture driver
mmap/poll file operation and several ioctl handlers are replaced
with the vb2 helper functions. Some helpers are used indirectly
to maintain the buffer queue ownership.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Sylwester Nawrocki [Wed, 20 Mar 2013 13:35:43 +0000 (10:35 -0300)]
[media] s5p-fimc: Use video entity for marking media pipeline as streaming
It doesn't matter whether we start from the sensor of from
the video node entity. Remove use of pipeline->subdevs array
where possible, so we can partly drop dependency on struct
fimc_pipeline in the fimc-lite module, which is also used
by the exynos5-is driver.
Also make sure we revert any media entity pipeline operations
when vb2_streamon() function fails.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Guennadi Liakhovetski [Wed, 26 Sep 2012 08:24:03 +0000 (05:24 -0300)]
[media] Add a V4L2 OF parser
Add a V4L2 OF parser, implementing bindings documented in
Documentation/devicetree/bindings/media/video-interfaces.txt.
[s.nawrocki@samsung.com: various corrections and improvements
since the initial version]
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Guennadi Liakhovetski [Tue, 11 Sep 2012 15:44:18 +0000 (12:44 -0300)]
[media] Add common video interfaces OF bindings documentation
This patch adds a document describing common OF bindings for video
capture, output and video processing devices. It is curently mainly
focused on video capture devices, with data busses defined by
standards such as ITU-R BT.656 or MIPI-CSI2.
It also documents a method of describing data links between devices.
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Linus Torvalds [Sat, 30 Mar 2013 20:13:05 +0000 (13:13 -0700)]
Merge git://git./linux/kernel/git/nab/target-pending
Pull SCSI target fixes from Nicholas Bellinger:
"This includes the bug-fix for a >= v3.8-rc1 regression specific to
iscsi-target persistent reservation conflict handling (CC'ed to
stable), and a tcm_vhost patch to drop VIRTIO_RING_F_EVENT_IDX usage
so that in-flight qemu vhost-scsi-pci device code can detect the
proper vhost feature bits.
Also, there are two more tcm_vhost patches still being discussed by
MST and Asias for v3.9 that will be required for the in-flight qemu
vhost-scsi-pci device patch to function properly, and that should
(hopefully) be the last target fixes for this round."
* git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending:
target: Fix RESERVATION_CONFLICT status regression for iscsi-target special case
tcm_vhost: Avoid VIRTIO_RING_F_EVENT_IDX feature bit
Andy Shevchenko [Wed, 20 Feb 2013 11:52:17 +0000 (13:52 +0200)]
dw_dmac: adjust slave_id accordingly to request line base
On some hardware configurations we have got the request line with the offset.
The patch introduces convert_slave_id() helper for that cases. The request line
base is came from the driver data provided by the platform_device_id table.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Viresh Kumar <viresh.kumar@linaro.org>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Arnd Bergmann [Sun, 3 Mar 2013 20:51:28 +0000 (20:51 +0000)]
dmaengine: dw_dma: fix endianess for DT xlate function
As reported by Wu Fengguang's build robot tracking sparse warnings, the
dma_spec arguments in the dw_dma_xlate are already byte swapped on
little-endian platforms and must not get swapped again. This code is
currently not used anywhere, but will be used in Linux 3.10 when the
ARM SPEAr platform starts using the generic DMA DT binding.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Rafael J. Wysocki [Fri, 29 Mar 2013 21:59:53 +0000 (22:59 +0100)]
PNP: List Rafael Wysocki as a maintainer
The Adam Belay's e-mail address in MAINTAINERS under PNP SUPPORT
is not valid any more and I started to maintain that code in the
meantime as a matter of fact, so list myself as a maintainer of it
along with Bjorn and remove the Adam's entry from it.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Fri, 29 Mar 2013 18:47:43 +0000 (11:47 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/sage/ceph-client
Pull ceph fix from Sage Weil:
"This fixes a regression introduced during the last merge window when
mapping non-existent images."
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
rbd: don't zero-fill non-image object requests
Alex Elder [Wed, 27 Mar 2013 14:16:30 +0000 (09:16 -0500)]
rbd: don't zero-fill non-image object requests
A result of ENOENT from a read request for an object that's part of
an rbd image indicates that there is a hole in that portion of the
image. Similarly, a short read for such an object indicates that
the remainder of the read should be interpreted a full read with
zeros filling out the end of the request.
This behavior is not correct for objects that are not backing rbd
image data. Currently rbd_img_obj_request_callback() assumes it
should be done for all objects.
Change rbd_img_obj_request_callback() so it only does this zeroing
for image objects. Encapsulate that special handling in its own
function. Add an assertion that the image object request is a bio
request, since we assume that (and we currently don't support any
other types).
This resolves a problem identified here:
http://tracker.ceph.com/issues/4559
The regression was introduced by
bf0d5f503dc11d6314c0503591d258d60ee9c944.
Reported-by: Dan van der Ster <dan@vanderster.com>
Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-off-by: Sage Weil <sage@inktank.com>
Linus Torvalds [Fri, 29 Mar 2013 18:13:25 +0000 (11:13 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/mason/linux-btrfs
Pull btrfs fixes from Chris Mason:
"We've had a busy two weeks of bug fixing. The biggest patches in here
are some long standing early-enospc problems (Josef) and a very old
race where compression and mmap combine forces to lose writes (me).
I'm fairly sure the mmap bug goes all the way back to the introduction
of the compression code, which is proof that fsx doesn't trigger every
possible mmap corner after all.
I'm sure you'll notice one of these is from this morning, it's a small
and isolated use-after-free fix in our scrub error reporting. I
double checked it here."
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
Btrfs: don't drop path when printing out tree errors in scrub
Btrfs: fix wrong return value of btrfs_lookup_csum()
Btrfs: fix wrong reservation of csums
Btrfs: fix double free in the btrfs_qgroup_account_ref()
Btrfs: limit the global reserve to 512mb
Btrfs: hold the ordered operations mutex when waiting on ordered extents
Btrfs: fix space accounting for unlink and rename
Btrfs: fix space leak when we fail to reserve metadata space
Btrfs: fix EIO from btrfs send in is_extent_unchanged for punched holes
Btrfs: fix race between mmap writes and compression
Btrfs: fix memory leak in btrfs_create_tree()
Btrfs: fix locking on ROOT_REPLACE operations in tree mod log
Btrfs: fix missing qgroup reservation before fallocating
Btrfs: handle a bogus chunk tree nicely
Btrfs: update to use fs_state bit
Len Brown [Fri, 29 Mar 2013 18:02:30 +0000 (11:02 -0700)]
ia64 idle: delete stale (*idle)() function pointer
Commit
3e7fc708eb41 ("ia64 idle: delete pm_idle") in 3.9-rc1 didn't
finish the job, leaving an un-initialized reference to (*idle)().
[ Haven't seen a crash from this - but seems like we are just being
lucky that "idle" is zero so it does get initialized before we jump to
randomland - Len ]
Reported-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Len Brown <len.brown@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Fri, 29 Mar 2013 18:00:43 +0000 (11:00 -0700)]
Merge branch 'for-curr' of git://git./linux/kernel/git/vgupta/arc
Pull arc architecture fixes from Vineet Gupta:
"This includes fix for a serious bug in DMA mapping API, make
allyesconfig wreckage, removal of bogus email-list placeholder in
MAINTAINERS, a typo in ptrace helper code and last remaining changes
for syscall ABI v3 which we are finally starting to transition-to
internally.
The request is late than I intended to - but I was held up with
debugging a timer link list corruption, for which a proposed fix to
generic timer code was sent out to lkml/tglx earlier today."
* 'for-curr' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc:
ARC: Fix the typo in event identifier flags used by ptrace
arc: fix dma_address assignment during dma_map_sg()
ARC: Remove SET_PERSONALITY (tracks cross-arch change)
ARC: ABIv3: fork/vfork wrappers not needed in "no-legacy-syscall" ABI
ARC: ABIv3: Print the correct ABI ver
ARC: make allyesconfig build breakages
ARC: MAINTAINERS update for ARC
Hans Verkuil [Fri, 29 Mar 2013 13:14:32 +0000 (10:14 -0300)]
[media] v4l2-controls.h: update private control ranges to prevent overlap
These ranges shouldn't overlap.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Hans Verkuil [Mon, 25 Mar 2013 09:43:12 +0000 (06:43 -0300)]
[media] media: move dvb-usb-v2/cypress_firmware.c to media/common
Loading the cypress firmware is not dvb specific and should be common
functionality. Move the source to media/common and make it a standalone
module.
As a result we can remove the dependency on dvb-usb in go7007, which has
nothing to do with dvb.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Josef Bacik [Fri, 29 Mar 2013 14:09:34 +0000 (08:09 -0600)]
Btrfs: don't drop path when printing out tree errors in scrub
A user reported a panic where we were panicing somewhere in
tree_backref_for_extent from scrub_print_warning. He only captured the trace
but looking at scrub_print_warning we drop the path right before we mess with
the extent buffer to print out a bunch of stuff, which isn't right. So fix this
by dropping the path after we use the eb if we need to. Thanks,
Cc: stable@vger.kernel.org
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Mauro Carvalho Chehab [Fri, 29 Mar 2013 12:43:14 +0000 (09:43 -0300)]
[media] radio-si476x: vidioc_s* now uses a const parameter
vidioc_s_tuner, vidioc_s_frequency and vidioc_s_register now
uses a constant argument. So, the driver reports warnings:
drivers/media/radio/radio-si476x.c:1196:2: warning: initialization from incompatible pointer type [enabled by default]
drivers/media/radio/radio-si476x.c:1196:2: warning: (near initialization for 'si4761_ioctl_ops.vidioc_s_tuner') [enabled by default]
drivers/media/radio/radio-si476x.c:1199:2: warning: initialization from incompatible pointer type [enabled by default]
drivers/media/radio/radio-si476x.c:1199:2: warning: (near initialization for 'si4761_ioctl_ops.vidioc_s_frequency') [enabled by default]
drivers/media/radio/radio-si476x.c:1209:2: warning: initialization from incompatible pointer type [enabled by default]
drivers/media/radio/radio-si476x.c:1209:2: warning: (near initialization for 'si4761_ioctl_ops.vidioc_s_register') [enabled by default]
This is due to a (soft) merge conflict, as both this driver and the
const patches were applied for the same Kernel version.
Cc: Hans Verkuil <hans.verkuil@cisco.com>
Cc: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>