Commit graph

663136 commits

Author SHA1 Message Date
Colin Ian King 678bc0adf7 [media] coda: remove redundant call to v4l2_m2m_get_vq
The call to v4ls_m2m_get_vq is only used to get the return value
which is not being used, so it appears to be redundant and can
be removed.

Detected with CoverityScan, CID#1420674 ("Useless call")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 14:38:40 -03:00
Hans Verkuil a9b99bbeda [media] em28xx: drop last soc_camera link
The em28xx driver still used the soc_camera.h header for the ov2640
driver. Since this driver no longer uses soc_camera, that include can
be removed.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 14:28:39 -03:00
Hans Verkuil ff0e9c1d6d [media] ov2640: add MC support
The MC support is needed by the em28xx driver.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 14:26:50 -03:00
Hans Verkuil 46796cfcd3 [media] ov2640: use standard clk and enable it
Convert v4l2_clk to normal clk and enable the clock.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Hugues Fruchet <hugues.fruchet@st.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:42:28 -03:00
Hans Verkuil 34aa88790b [media] ov2640: convert from soc-camera to a standard subdev sensor driver
Convert ov2640 to a standard subdev driver. The soc-camera driver no longer
uses this driver, so it can safely be converted.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Hugues Fruchet <hugues.fruchet@st.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:38:17 -03:00
Hans Verkuil ee044f5be1 [media] cec: fix confusing CEC_CAP_RC and IS_REACHABLE(CONFIG_RC_CORE) code
It is a bit confusing how CEC_CAP_RC and IS_REACHABLE(CONFIG_RC_CORE)
interact. By stripping CEC_CAP_RC at the beginning rather than after #else
it should be a bit clearer what is going on.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Reported-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:15:29 -03:00
Lee Jones 43c0c03961 [media] cec: Fix runtime BUG when (CONFIG_RC_CORE && !CEC_CAP_RC)
Currently when the RC Core is enabled (reachable) core code located
in cec_register_adapter() attempts to populate the RC structure with
a pointer to the 'parent' passed in by the caller.

Unfortunately if the caller did not specify RC capability when calling
cec_allocate_adapter(), then there will be no RC structure to populate.

This causes a "NULL pointer dereference" error.

Fixes: f51e80804f ("[media] cec: pass parent device in register(), not allocate()")

Signed-off-by: Lee Jones <lee.jones@linaro.org>
Cc: <stable@vger.kernel.org>      # for v4.10 and up
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:14:53 -03:00
Hans Verkuil a93d429b51 [media] s5p-cec: add cec-notifier support, move out of staging
By using the CEC notifier framework there is no longer any reason
to manually set the physical address. This was the one blocking
issue that prevented this driver from going out of staging, so do
this move as well.

Update the bindings documenting the new hdmi phandle and
update exynos4.dtsi accordingly.

Tested with my Odroid U3.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
CC: linux-samsung-soc@vger.kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:14:03 -03:00
Hans Verkuil efaedd17a3 [media] s5p-cec.txt: document the HDMI controller phandle
Update the bindings documenting the new hdmi phandle.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
Acked-by: Rob Herring <robh@kernel.org>
CC: linux-samsung-soc@vger.kernel.org
CC: devicetree@vger.kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:13:07 -03:00
Hans Verkuil dfa9739e64 [media] ARM: dts: exynos: add HDMI controller phandle to exynos4.dtsi
Add the new hdmi phandle to exynos4.dtsi. This phandle is needed by the
s5p-cec driver to initialize the CEC notifier framework.

Tested with my Odroid U3.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
CC: linux-samsung-soc@vger.kernel.org
CC: devicetree@vger.kernel.org
CC: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:12:41 -03:00
Hans Verkuil 278c811c5d [media] exynos_hdmi: add CEC notifier support
Implement the CEC notifier support to allow CEC drivers to
be informed when there is a new physical address.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:08:11 -03:00
Benjamin Gaignard ed3022de6d [media] ARM: dts: STiH410: update sti-cec for CEC notifier support
To use CEC notifier sti CEC driver needs to get phandle
of the hdmi device.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
CC: Patrice CHOTARD <patrice.chotard@st.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 13:07:36 -03:00
Benjamin Gaignard fc4e009c6c [media] stih-cec: add CEC notifier support
By using the CEC notifier framework there is no longer any reason
to manually set the physical address. This was the one blocking
issue that prevented this driver from going out of staging, so do
this move as well.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:53:51 -03:00
Benjamin Gaignard 6e27ccce8c [media] stih-cec.txt: document new hdmi phandle
Update the bindings documentation with the new hdmi phandle.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:52:37 -03:00
Benjamin Gaignard bca55958ea [media] sti: hdmi: add CEC notifier support
Implement the CEC notifier support to allow CEC drivers to
be informed when there is a new physical address.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:52:01 -03:00
Hans Verkuil e3a93adcc4 [media] cec: integrate CEC notifier support
Support the CEC notifier framework, simplifying drivers that
depend on this.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:49:19 -03:00
Hans Verkuil 6917a7b774 [media] media: add CEC notifier support
Add support for CEC notifiers, which is used to convey CEC physical address
information from video drivers to their CEC counterpart driver(s).

Based on an earlier version from Russell King:

https://patchwork.kernel.org/patch/9277043/

The cec_notifier is a reference counted object containing the CEC physical address
state of a video device.

When a new notifier is registered the current state will be reported to
that notifier at registration time.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Tested-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:48:28 -03:00
Antti Palosaari 0fc66c1949 [media] mn88472: implement PER statistics
Implement DVBv5 PER.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:44:26 -03:00
Antti Palosaari c635a5e2cf [media] mn88472: implement cnr statistics
Implement DVBv5 CNR.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:43:54 -03:00
Antti Palosaari 61d7c6aa4f [media] mn88472: implement signal strength statistics
Implement DVBv5 signal strength on relative scale.

Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:43:12 -03:00
Hans Verkuil 0f314f6c2e [media] rainshadow-cec: new RainShadow Tech HDMI CEC driver
This driver supports the RainShadow Tech USB HDMI CEC adapter.

See: http://rainshadowtech.com/HdmiCecUsb.html

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:42:10 -03:00
Hans Verkuil 04dffe1105 [media] serio.h: add SERIO_RAINSHADOW_CEC ID
Add a new serio ID for the RainShadow Tech USB HDMI CEC adapter.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 12:34:01 -03:00
Kieran Bingham 1531a208ed [media] v4l: vsp1: Register pipe with output WPF
The DRM object does not register the pipe with the WPF object. This is
used internally throughout the driver as a means of accessing the pipe.
As such this breaks operations which require access to the pipe from WPF
interrupts.

Register the pipe inside the WPF object after it has been declared as
the output.

Fixes: ff7e97c94d ("[media] v4l: vsp1: Store pipeline pointer in rwpf")

Signed-off-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:33:10 -03:00
Kieran Bingham 1b8ce4060b [media] v4l: vsp1: Fix struct vsp1_drm documentation
The struct vsp1_drm references a member 'planes' which doesn't exist.
Correctly identify this documentation against the 'inputs'

Signed-off-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:32:47 -03:00
Laurent Pinchart 40ad34d8eb [media] v4l: vsp1: Disable HSV formats on Gen3 hardware
While all VSP instances can process HSV internally, on Gen3 hardware
reading or writing HSV24 or HSV32 from/to memory causes the device to
hang. Disable those pixel formats on Gen3 hardware.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:32:21 -03:00
Laurent Pinchart 9dbed95ba6 [media] v4l: vsp1: Fix multi-line comment style
Fix all multi-line comments to comply with the kernel coding style.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:31:39 -03:00
Kieran Bingham f2074708ee [media] v4l: vsp1: Remove redundant pipe->dl usage from drm
The pipe->dl is used only inside vsp1_du_atomic_flush(), and can be
obtained and stored locally to simplify the code.

Signed-off-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:29:57 -03:00
Kieran Bingham 4461c84b52 [media] v4l: vsp1: Prevent multiple streamon race commencing pipeline early
With multiple inputs through the BRU it is feasible for the streams to
race each other at stream-on.

Multiple VIDIOC_STREAMON calls racing each other could have process
N-1 skipping over the pipeline setup section and then start the pipeline
early, if videobuf2 has already enqueued buffers to the driver for
process N but not called the .start_streaming() operation yet

In the case of the video pipelines, this
can present two serious issues.

 1) A null-dereference if the pipe->dl is committed at the same time as
    the vsp1_video_setup_pipeline() is processing

 2) A hardware hang, where a display list is committed without having
    called vsp1_video_setup_pipeline() first

Repair this issue, by ensuring that only the stream which configures the
pipeline is able to start it.

Signed-off-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:28:50 -03:00
Laurent Pinchart 3425382288 [media] v4l: vsp1: Fix RPF/WPF U/V order in 3-planar formats on Gen3
The RPF and WPF U/V order bits have no effect for 3-planar formats on
Gen3 hardware. Swap the U and V planes addresses manually instead in
that case.

Fixes: b915bd24a0 ("[media] v4l: vsp1: Add tri-planar memory formats support")

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:28:19 -03:00
Shailendra Verma dadc3be66c [media] v4l: vsp1: Clean up file handle in open() error path
v4l2_fh_init is already done. So call the v4l2_fh_exit in error
condition before returing from the function.

Signed-off-by: Shailendra Verma <shailendra.v@samsung.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:27:25 -03:00
Kieran Bingham f145016254 [media] v4l: vsp1: Fix format-info documentation
Minor tweaks to document the swap register and make the documentation
match the struct ordering

Signed-off-by: Kieran Bingham <kieran@bingham.xyz>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:25:07 -03:00
Hans Verkuil 426b188040 [media] dev-capture.rst/dev-output.rst: video standards ioctls are optional
The documentation for video capture and output devices claims that the video standard
ioctls are required. This is not the case, they are only required for PAL/NTSC/SECAM
type inputs and outputs. Sensors do not implement this at all and e.g. HDMI inputs
implement the DV Timings ioctls.

Just drop the mention of 'video standard' ioctls.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:23:08 -03:00
Hans Verkuil 0538bee6fd [media] MAINTAINERS: update atmel-isi.c path
The driver moved to drivers/media/platform/atmel.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:13:08 -03:00
Hans Verkuil 9f994253c8 [media] ov2640: update bindings
Update the bindings for this device based on a working DT example.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Rob Herring <robh@kernel.org>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:12:21 -03:00
Hans Verkuil 9823f003b9 [media] ov2640: fix colorspace handling
The colorspace is independent of whether YUV or RGB is sent to the SoC.
Fix this.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:00:34 -03:00
Hans Verkuil c1d82b8953 [media] atmel-isi: move out of soc_camera to atmel
Move this out of the soc_camera directory into the atmel directory
where it belongs.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 08:00:06 -03:00
Hans Verkuil d12c9088c0 [media] atmel-isi: remove dependency of the soc-camera framework
This patch converts the atmel-isi driver from a soc-camera driver to a driver
that is stand-alone.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:58:58 -03:00
Hans Verkuil e48f4eeac1 [media] atmel-isi: update device tree bindings documentation
The original bindings documentation was incomplete (missing pinctrl-names,
missing endpoint node properties) and the example was out of date.

Add the missing information and tidy up the text.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:55:24 -03:00
Hans Verkuil a0c4164e0e [media] ov7670: add devicetree support
Add DT support. Use it to get the reset and pwdn pins (if there are any).
Tested with one sensor requiring reset/pwdn and one sensor that doesn't
have reset/pwdn pins.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:54:06 -03:00
Hans Verkuil 0a024d634c [media] ov7670: get xclk
Get the clock for this sensor.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:53:27 -03:00
Hans Verkuil d569e90bb7 [media] ov7670: fix g/s_parm
Drop unnecesary memset. Drop the unnecessary extendedmode check and
set the V4L2_CAP_TIMEPERFRAME capability.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:52:59 -03:00
Hans Verkuil 7d1b8619ea [media] ov7670: call v4l2_async_register_subdev
Add v4l2-async support for this driver.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:52:31 -03:00
Hans Verkuil bba582894a [media] ov7670: document device tree bindings
Add binding documentation and add that file to the MAINTAINERS entry.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:51:08 -03:00
Daniel Patrick Johnson c4a0968aea [media] uvcvideo: Add support for Intel SR300 depth camera
Add support for Intel SR300 depth camera in uvc driver.
This includes adding three uvc GUIDs for the required pixel formats
and updating the uvc driver GUID-to-4cc tables with the new formats.

Signed-off-by: Daniel Patrick Johnson <teknotus@teknot.us>
Signed-off-by: Aviv Greenberg <avivgr@gmail.com>
Signed-off-by: Evgeni Raikhel <evgeni.raikhel@intel.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:47:34 -03:00
Evgeni Raikhel 5df082e231 [media] Documentation: Intel SR300 Depth camera INZI format
Provide the frame structure and data layout of V4L2-PIX-FMT-INZI
format utilized by Intel SR300 Depth camera.

Signed-off-by: Evgeni Raikhel <evgeni.raikhel@intel.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:46:42 -03:00
Kieran Bingham 52276df0b1 [media] uvcvideo: Don't record timespec_sub
The statistics function subtracts two timespecs manually. A helper is
provided by the kernel to do this.

Replace the implementation, using the helper.

Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:42:12 -03:00
Kieran Bingham 360a3a90c6 [media] uvcvideo: Fix empty packet statistic
The frame counters are inadvertently counting packets with content as
empty.

Fix it by correcting the logic expression

Fixes: 7bc5edb00b [media] uvcvideo: Extract video stream statistics

Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:41:27 -03:00
Hans Verkuil f098268bd6 [media] v4l2-ctrls.c: fix RGB quantization range control menu
All control menus use the english capitalization rules of titles.

The only menu not following these rules is the RGB Quantization Range control
menu. Fix this.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:35:21 -03:00
Johan Hovold 65f921647f [media] cx231xx-audio: fix NULL-deref at probe
Make sure to check the number of endpoints to avoid dereferencing a
NULL-pointer or accessing memory beyond the endpoint array should a
malicious device lack the expected endpoints.

Fixes: e0d3bafd02 ("V4L/DVB (10954): Add cx231xx USB driver")

Cc: stable <stable@vger.kernel.org>     # 2.6.30
Cc: Sri Deevi <Srinivasa.Deevi@conexant.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:34:46 -03:00
Johan Hovold fff1abc4d5 [media] cx231xx-audio: fix init error path
Make sure to release the snd_card also on a late allocation error.

Fixes: e0d3bafd02 ("V4L/DVB (10954): Add cx231xx USB driver")

Cc: stable <stable@vger.kernel.org>     # 2.6.30
Cc: Sri Deevi <Srinivasa.Deevi@conexant.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-04-10 07:34:10 -03:00