Commit 71f3a82f authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'media/v4.19-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media

Pull media updates from Mauro Carvalho Chehab:

 - new Socionext MN88443x ISDB-S/T demodulator driver: mn88443x

 - new sensor drivers: ak7375, ov2680 and rj54n1cb0c

 - an old soc-camera sensor driver converted to the V4L2 framework:
   mt9v111

 - a new Voice-Coil Motor (VCM) driver: dw9807-vcm

 - some cleanups at cx25821, removing legacy unused code

 - some improvements at ddbridge driver

 - new platform driver: vicodec

 - some DVB API cleanups, removing ioctls and compat code for old
   out-of-tree drivers that were never merged upstream

 - improvements at DVB core to support frontents that support both
   Satellite and non-satellite delivery systems

 - got rid of the unused VIDIOC_RESERVED V4L2 ioctl

 - some cleanups/improvements at gl861 ISDB driver

 - several improvements on ov772x, ov7670 and ov5640, imx274, ov5645,
   and smiapp sensor drivers

 - fixes at em28xx to support dual TS devices

 - some cleanups at V4L2/VB2 locking logic

 - some API improvements at media controller

 - some cec core and drivers improvements

 - some uvcvideo improvements

 - some improvements at platform drivers: stm32-dcmi, rcar-vin, coda,
   reneseas-ceu, imx, vsp1, venus, camss

 - lots of other cleanups and fixes

* tag 'media/v4.19-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (406 commits)
  Revert "media: vivid: shut up warnings due to a non-trivial logic"
  siano: get rid of an unused return code for debugfs register
  media: isp: fix a warning about a wrong struct initializer
  media: radio-wl1273: fix return code for the polling routine
  media: s3c-camif: fix return code for the polling routine
  media: saa7164: fix return codes for the polling routine
  media: exynos-gsc: fix return code if mutex was interrupted
  media: mt9v111: Fix build error with no VIDEO_V4L2_SUBDEV_API
  media: xc4000: get rid of uneeded casts
  media: drxj: get rid of uneeded casts
  media: tuner-xc2028: don't use casts for printing sizes
  media: cleanup fall-through comments
  media: vivid: shut up warnings due to a non-trivial logic
  media: rtl28xxu: be sure that it won't go past the array size
  media: mt9v111: avoid going past the buffer
  media: vsp1_dl: add a description for cmdpool field
  media: sta2x11: add a missing parameter description
  media: v4l2-mem2mem: add descriptions to MC fields
  media: i2c: fix warning in Aptina MT9V111
  media: imx: shut up a false positive warning
  ...
parents 54dbe75b da2048b7
......@@ -4,8 +4,8 @@ The HDMI CEC GPIO module supports CEC implementations where the CEC line
is hooked up to a pull-up GPIO line and - optionally - the HPD line is
hooked up to another GPIO line.
Please note: the maximum voltage for the CEC line is 3.63V, for the HPD
line it is 5.3V. So you may need some sort of level conversion circuitry
Please note: the maximum voltage for the CEC line is 3.63V, for the HPD and
5V lines it is 5.3V. So you may need some sort of level conversion circuitry
when connecting them to a GPIO line.
Required properties:
......@@ -19,18 +19,24 @@ following property is also required:
- hdmi-phandle - phandle to the HDMI controller, see also cec.txt.
If the CEC line is not associated with an HDMI receiver/transmitter, then
the following property is optional:
the following property is optional and can be used for debugging HPD changes:
- hpd-gpios: gpio that the HPD line is connected to.
This property is optional and can be used for debugging changes on the 5V line:
- v5-gpios: gpio that the 5V line is connected to.
Example for the Raspberry Pi 3 where the CEC line is connected to
pin 26 aka BCM7 aka CE1 on the GPIO pin header and the HPD line is
connected to pin 11 aka BCM17 (some level shifter is needed for this!):
pin 26 aka BCM7 aka CE1 on the GPIO pin header, the HPD line is
connected to pin 11 aka BCM17 and the 5V line is connected to pin
15 aka BCM22 (some level shifter is needed for the HPD and 5V lines!):
#include <dt-bindings/gpio/gpio.h>
cec-gpio {
compatible = "cec-gpio";
cec-gpios = <&gpio 7 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
hpd-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
compatible = "cec-gpio";
cec-gpios = <&gpio 7 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
hpd-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
v5-gpios = <&gpio 22 GPIO_ACTIVE_HIGH>;
};
Asahi Kasei Microdevices AK7375 voice coil lens driver
AK7375 is a camera voice coil lens.
Mandatory properties:
- compatible: "asahi-kasei,ak7375"
- reg: I2C slave address
* Aptina MT9V111 CMOS sensor
----------------------------
The Aptina MT9V111 is a 1/4-Inch VGA-format digital image sensor with a core
based on Aptina MT9V011 sensor and an integrated Image Flow Processor (IFP).
The sensor has an active pixel array of 640x480 pixels and can output a number
of image resolution and formats controllable through a simple two-wires
interface.
Required properties:
--------------------
- compatible: shall be "aptina,mt9v111".
- clocks: reference to the system clock input provider.
Optional properties:
--------------------
- enable-gpios: output enable signal, pin name "OE#". Active low.
- standby-gpios: low power state control signal, pin name "STANDBY".
Active high.
- reset-gpios: chip reset signal, pin name "RESET#". Active low.
The device node must contain one 'port' child node with one 'endpoint' child
sub-node for its digital output video port, in accordance with the video
interface bindings defined in:
Documentation/devicetree/bindings/media/video-interfaces.txt
Example:
--------
&i2c1 {
camera@48 {
compatible = "aptina,mt9v111";
reg = <0x48>;
clocks = <&camera_clk>;
port {
mt9v111_out: endpoint {
remote-endpoint = <&ceu_in>;
};
};
};
};
Dongwoon Anatech DW9807 voice coil lens driver
DW9807 is a 10-bit DAC with current sink capability. It is intended for
controlling voice coil lenses.
Mandatory properties:
- compatible: "dongwoon,dw9807-vcm"
- reg: I2C slave address
......@@ -29,6 +29,9 @@ Optional properties
- reset-gpios: XSHUTDOWN GPIO
- flash-leds: See ../video-interfaces.txt
- lens-focus: See ../video-interfaces.txt
- rotation: Integer property; valid values are 0 (sensor mounted upright)
and 180 (sensor mounted upside down). See
../video-interfaces.txt .
Endpoint node mandatory properties
......
* Omnivision OV2680 MIPI CSI-2 sensor
Required Properties:
- compatible: should be "ovti,ov2680".
- clocks: reference to the xvclk input clock.
- clock-names: should be "xvclk".
- DOVDD-supply: Digital I/O voltage supply.
- DVDD-supply: Digital core voltage supply.
- AVDD-supply: Analog voltage supply.
Optional Properties:
- reset-gpios: reference to the GPIO connected to the powerdown/reset pin,
if any. This is an active low signal to the OV2680.
The device node must contain one 'port' child node for its digital output
video port, and this port must have a single endpoint in accordance with
the video interface bindings defined in
Documentation/devicetree/bindings/media/video-interfaces.txt.
Endpoint node required properties for CSI-2 connection are:
- remote-endpoint: a phandle to the bus receiver's endpoint node.
- clock-lanes: should be set to <0> (clock lane on hardware lane 0).
- data-lanes: should be set to <1> (one CSI-2 lane supported).
Example:
&i2c2 {
ov2680: camera-sensor@36 {
compatible = "ovti,ov2680";
reg = <0x36>;
clocks = <&osc>;
clock-names = "xvclk";
reset-gpios = <&gpio1 3 GPIO_ACTIVE_LOW>;
DOVDD-supply = <&sw2_reg>;
DVDD-supply = <&sw2_reg>;
AVDD-supply = <&reg_peri_3p15v>;
port {
ov2680_to_mipi: endpoint {
remote-endpoint = <&mipi_from_sensor>;
clock-lanes = <0>;
data-lanes = <1>;
};
};
};
};
......@@ -13,6 +13,10 @@ Optional Properties:
This is an active low signal to the OV5640.
- powerdown-gpios: reference to the GPIO connected to the powerdown pin,
if any. This is an active high signal to the OV5640.
- rotation: as defined in
Documentation/devicetree/bindings/media/video-interfaces.txt,
valid values are 0 (sensor mounted upright) and 180 (sensor
mounted upside down).
The device node must contain one 'port' child node for its digital output
video port, in accordance with the video interface bindings defined in
......@@ -51,6 +55,7 @@ Examples:
DVDD-supply = <&vgen2_reg>; /* 1.5v */
powerdown-gpios = <&gpio1 19 GPIO_ACTIVE_HIGH>;
reset-gpios = <&gpio1 20 GPIO_ACTIVE_LOW>;
rotation = <180>;
port {
/* MIPI CSI-2 bus endpoint */
......
......@@ -27,9 +27,15 @@ Required properties:
- sxe
- clocks : Must include the following entries:
- vde
- resets : Must include the following entries:
- resets : Must contain an entry for each entry in reset-names.
- reset-names : Should include the following entries:
- vde
Optional properties:
- resets : Must contain an entry for each entry in reset-names.
- reset-names : Must include the following entries:
- mc
Example:
video-codec@6001a000 {
......@@ -51,5 +57,6 @@ video-codec@6001a000 {
<GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>; /* SXE interrupt */
interrupt-names = "sync-token", "bsev", "sxe";
clocks = <&tegra_car TEGRA20_CLK_VDE>;
resets = <&tegra_car 61>;
reset-names = "vde", "mc";
resets = <&tegra_car 61>, <&mc TEGRA20_MC_RESET_VDE>;
};
......@@ -5,8 +5,9 @@ Qualcomm Camera Subsystem
- compatible:
Usage: required
Value type: <stringlist>
Definition: Should contain:
Definition: Should contain one of:
- "qcom,msm8916-camss"
- "qcom,msm8996-camss"
- reg:
Usage: required
Value type: <prop-encoded-array>
......@@ -19,11 +20,16 @@ Qualcomm Camera Subsystem
- "csiphy0_clk_mux"
- "csiphy1"
- "csiphy1_clk_mux"
- "csiphy2" (8996 only)
- "csiphy2_clk_mux" (8996 only)
- "csid0"
- "csid1"
- "csid2" (8996 only)
- "csid3" (8996 only)
- "ispif"
- "csi_clk_mux"
- "vfe0"
- "vfe1" (8996 only)
- interrupts:
Usage: required
Value type: <prop-encoded-array>
......@@ -34,10 +40,14 @@ Qualcomm Camera Subsystem
Definition: Should contain the following entries:
- "csiphy0"
- "csiphy1"
- "csiphy2" (8996 only)
- "csid0"
- "csid1"
- "csid2" (8996 only)
- "csid3" (8996 only)
- "ispif"
- "vfe0"
- "vfe1" (8996 only)
- power-domains:
Usage: required
Value type: <prop-encoded-array>
......@@ -53,25 +63,42 @@ Qualcomm Camera Subsystem
Usage: required
Value type: <stringlist>
Definition: Should contain the following entries:
- "camss_top_ahb"
- "ispif_ahb"
- "csiphy0_timer"
- "csiphy1_timer"
- "csi0_ahb"
- "csi0"
- "csi0_phy"
- "csi0_pix"
- "csi0_rdi"
- "csi1_ahb"
- "csi1"
- "csi1_phy"
- "csi1_pix"
- "csi1_rdi"
- "camss_ahb"
- "camss_vfe_vfe"
- "camss_csi_vfe"
- "iface"
- "bus"
- "top_ahb"
- "ispif_ahb"
- "csiphy0_timer"
- "csiphy1_timer"
- "csiphy2_timer" (8996 only)
- "csi0_ahb"
- "csi0"
- "csi0_phy"
- "csi0_pix"
- "csi0_rdi"
- "csi1_ahb"
- "csi1"
- "csi1_phy"
- "csi1_pix"
- "csi1_rdi"
- "csi2_ahb" (8996 only)
- "csi2" (8996 only)
- "csi2_phy" (8996 only)
- "csi2_pix" (8996 only)
- "csi2_rdi" (8996 only)
- "csi3_ahb" (8996 only)
- "csi3" (8996 only)
- "csi3_phy" (8996 only)
- "csi3_pix" (8996 only)
- "csi3_rdi" (8996 only)
- "ahb"
- "vfe0"
- "csi_vfe0"
- "vfe0_ahb", (8996 only)
- "vfe0_stream", (8996 only)
- "vfe1", (8996 only)
- "csi_vfe1", (8996 only)
- "vfe1_ahb", (8996 only)
- "vfe1_stream", (8996 only)
- "vfe_ahb"
- "vfe_axi"
- vdda-supply:
Usage: required
Value type: <phandle>
......@@ -90,22 +117,27 @@ Qualcomm Camera Subsystem
- reg:
Usage: required
Value type: <u32>
Definition: Selects CSI2 PHY interface - PHY0 or PHY1.
Definition: Selects CSI2 PHY interface - PHY0, PHY1
or PHY2 (8996 only)
Endpoint node properties:
- clock-lanes:
Usage: required
Value type: <u32>
Definition: The physical clock lane index. The value
must always be <1> as the physical clock
lane is lane 1.
Definition: The physical clock lane index. On 8916
the value must always be <1> as the physical
clock lane is lane 1. On 8996 the value must
always be <7> as the hardware supports D-PHY
and C-PHY, indexes are in a common set and
D-PHY physical clock lane is labeled as 7.
- data-lanes:
Usage: required
Value type: <prop-encoded-array>
Definition: An array of physical data lanes indexes.
Position of an entry determines the logical
lane number, while the value of an entry
indicates physical lane index. Lane swapping
is supported.
Definition: An array of physical data lanes indexes.
Position of an entry determines the logical
lane number, while the value of an entry
indicates physical lane index. Lane swapping
is supported. Physical lane indexes for
8916: 0, 2, 3, 4; for 8996: 0, 1, 2, 3.
* An Example
......@@ -161,25 +193,25 @@ Qualcomm Camera Subsystem
<&gcc GCC_CAMSS_CSI_VFE0_CLK>,
<&gcc GCC_CAMSS_VFE_AHB_CLK>,
<&gcc GCC_CAMSS_VFE_AXI_CLK>;
clock-names = "camss_top_ahb",
"ispif_ahb",
"csiphy0_timer",
"csiphy1_timer",
"csi0_ahb",
"csi0",
"csi0_phy",
"csi0_pix",
"csi0_rdi",
"csi1_ahb",
"csi1",
"csi1_phy",
"csi1_pix",
"csi1_rdi",
"camss_ahb",
"camss_vfe_vfe",
"camss_csi_vfe",
"iface",
"bus";
clock-names = "top_ahb",
"ispif_ahb",
"csiphy0_timer",
"csiphy1_timer",
"csi0_ahb",
"csi0",
"csi0_phy",
"csi0_pix",
"csi0_rdi",
"csi1_ahb",
"csi1",
"csi1_phy",
"csi1_pix",
"csi1_rdi",
"ahb",
"vfe0",
"csi_vfe0",
"vfe_ahb",
"vfe_axi";
vdda-supply = <&pm8916_l2>;
iommus = <&apps_iommu 3>;
ports {
......
......@@ -6,6 +6,7 @@
Definition: Value should contain one of:
- "qcom,msm8916-venus"
- "qcom,msm8996-venus"
- "qcom,sdm845-venus"
- reg:
Usage: required
Value type: <prop-encoded-array>
......
......@@ -21,7 +21,9 @@ on Gen3 platforms to a CSI-2 receiver.
- "renesas,vin-r8a7794" for the R8A7794 device
- "renesas,vin-r8a7795" for the R8A7795 device
- "renesas,vin-r8a7796" for the R8A7796 device
- "renesas,vin-r8a77965" for the R8A77965 device
- "renesas,vin-r8a77970" for the R8A77970 device
- "renesas,vin-r8a77995" for the R8A77995 device
- "renesas,rcar-gen2-vin" for a generic R-Car Gen2 or RZ/G1 compatible
device.
......@@ -37,30 +39,51 @@ Additionally, an alias named vinX will need to be created to specify
which video input device this is.
The per-board settings Gen2 platforms:
- port sub-node describing a single endpoint connected to the vin
as described in video-interfaces.txt[1]. Only the first one will
be considered as each vin interface has one input port.
- port - sub-node describing a single endpoint connected to the VIN
from external SoC pins as described in video-interfaces.txt[1].
Only the first one will be considered as each vin interface has one
input port.
- Optional properties for endpoint nodes:
- hsync-active: see [1] for description. Default is active high.
- vsync-active: see [1] for description. Default is active high.
If both HSYNC and VSYNC polarities are not specified, embedded
synchronization is selected.
- field-active-even: see [1] for description. Default is active high.
- bus-width: see [1] for description. The selected bus width depends on
the SoC type and selected input image format.
Valid values are: 8, 10, 12, 16, 24 and 32.
- data-shift: see [1] for description. Valid values are 0 and 8.
- data-enable-active: polarity of CLKENB signal, see [1] for
description. Default is active high.
The per-board settings Gen3 platforms:
Gen3 platforms can support both a single connected parallel input source
from external SoC pins (port0) and/or multiple parallel input sources
from local SoC CSI-2 receivers (port1) depending on SoC.
from external SoC pins (port@0) and/or multiple parallel input sources
from local SoC CSI-2 receivers (port@1) depending on SoC.
- renesas,id - ID number of the VIN, VINx in the documentation.
- ports
- port 0 - sub-node describing a single endpoint connected to the VIN
from external SoC pins described in video-interfaces.txt[1].
Describing more then one endpoint in port 0 is invalid. Only VIN
instances that are connected to external pins should have port 0.
- port 1 - sub-nodes describing one or more endpoints connected to
- port@0 - sub-node describing a single endpoint connected to the VIN
from external SoC pins as described in video-interfaces.txt[1].
Describing more than one endpoint in port@0 is invalid. Only VIN
instances that are connected to external pins should have port@0.
Endpoint nodes of port@0 support the optional properties listed in
the Gen2 per-board settings description.
- port@1 - sub-nodes describing one or more endpoints connected to
the VIN from local SoC CSI-2 receivers. The endpoint numbers must
use the following schema.
- Endpoint 0 - sub-node describing the endpoint connected to CSI20
- Endpoint 1 - sub-node describing the endpoint connected to CSI21
- Endpoint 2 - sub-node describing the endpoint connected to CSI40
- Endpoint 3 - sub-node describing the endpoint connected to CSI41
- endpoint@0 - sub-node describing the endpoint connected to CSI20
- endpoint@1 - sub-node describing the endpoint connected to CSI21
- endpoint@2 - sub-node describing the endpoint connected to CSI40
- endpoint@3 - sub-node describing the endpoint connected to CSI41
Endpoint nodes of port@1 do not support any optional endpoint property.
Device node example for Gen2 platforms
--------------------------------------
......@@ -107,9 +130,6 @@ Board setup example for Gen2 platforms (vin1 composite video input)