Commit fa73e212 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull media updates from Mauro Carvalho Chehab:

 - Legacy soc_camera driver was removed from staging

 - New I2C sensor related drivers: dw9768, ch7322, max9271, rdacm20

 - TI vpe driver code was re-organized and had new features added

 - Added Xilinx MIPI CSI-2 Rx Subsystem driver

 - Added support for Infrared Toy and IR Droid devices

 - Lots of random driver fixes, new features and cleanups

* tag 'media/v5.9-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (318 commits)
  media: camss: fix memory leaks on error handling paths in probe
  media: davinci: vpif_capture: fix potential double free
  media: radio: remove redundant assignment to variable retval
  media: allegro: fix potential null dereference on header
  media: mtk-mdp: Fix a refcounting bug on error in init
  media: allegro: fix an error pointer vs NULL check
  media: meye: fix missing pm_mchip_mode field
  media: cafe-driver: use generic power management
  media: saa7164: use generic power management
  media: v4l2-dev/ioctl: Fix document for VIDIOC_QUERYCAP
  media: v4l2: Correct kernel-doc inconsistency
  media: v4l2: Correct kernel-doc inconsistency
  media: dvbdev.h: keep * together with the type
  media: v4l2-subdev.h: keep * together with the type
  media: videobuf2: Print videobuf2 buffer state by name
  media: colorspaces-details.rst: fix V4L2_COLORSPACE_JPEG description
  media: tw68: use generic power management
  media: meye: use generic power management
  media: cx88: use generic power management
  media: cx25821: use generic power management
  ...
parents 75dee3b6 f45882cf
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@

.. include:: <isonum.txt>

The Samsung S5P/EXYNOS4 FIMC driver
The Samsung S5P/Exynos4 FIMC driver
===================================

Copyright |copy| 2012 - 2013 Samsung Electronics Co., Ltd.
@@ -19,7 +19,7 @@ drivers/media/platform/exynos4-is directory.
Supported SoCs
--------------

S5PC100 (mem-to-mem only), S5PV210, EXYNOS4210
S5PC100 (mem-to-mem only), S5PV210, Exynos4210

Supported features
------------------
@@ -45,7 +45,7 @@ Media device interface
~~~~~~~~~~~~~~~~~~~~~~

The driver supports Media Controller API as defined at :ref:`media_controller`.
The media device driver name is "SAMSUNG S5P FIMC".
The media device driver name is "Samsung S5P FIMC".

The purpose of this interface is to allow changing assignment of FIMC instances
to the SoC peripheral camera input at runtime and optionally to control internal
+9 −0
Original line number Diff line number Diff line
@@ -293,6 +293,15 @@ all configurable using the following module options:
		- 0: vmalloc
		- 1: dma-contig

- cache_hints:

	specifies if the device should set queues' user-space cache and memory
	consistency hint capability (V4L2_BUF_CAP_SUPPORTS_MMAP_CACHE_HINTS).
	The hints are valid only when using MMAP streaming I/O. Default is 0.

		- 0: forbid hints
		- 1: allow hints

Taken together, all these module options allow you to precisely customize
the driver behavior and test your application with all sorts of permutations.
It is also very suitable to emulate hardware that is not yet available, e.g.
+67 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: "http://devicetree.org/schemas/media/i2c/chrontel,ch7322.yaml#"
$schema: "http://devicetree.org/meta-schemas/core.yaml#"

title: Chrontel HDMI-CEC Controller

maintainers:
  - Jeff Chase <jnchase@google.com>

description:
  The Chrontel CH7322 is a discrete HDMI-CEC controller. It is
  programmable through I2C and drives a single CEC line.

properties:
  compatible:
    const: chrontel,ch7322

  reg:
    description: I2C device address
    maxItems: 1

  clocks:
    maxItems: 1

  interrupts:
    maxItems: 1

  reset-gpios:
    description:
      Reference to the GPIO connected to the RESET pin, if any. This
      pin is active-low.
    maxItems: 1

  standby-gpios:
    description:
      Reference to the GPIO connected to the OE pin, if any. When low
      the device will respond to power status requests with "standby"
      if in auto mode.
    maxItems: 1

  # see ../cec.txt
  hdmi-phandle:
    description: phandle to the HDMI controller

required:
  - compatible
  - reg
  - interrupts

examples:
  - |
    #include <dt-bindings/gpio/gpio.h>
    #include <dt-bindings/interrupt-controller/irq.h>
    i2c {
      #address-cells = <1>;
      #size-cells = <0>;
      ch7322@75 {
        compatible = "chrontel,ch7322";
        reg = <0x75>;
        interrupts = <47 IRQ_TYPE_EDGE_RISING>;
        standby-gpios = <&gpio 16 GPIO_ACTIVE_LOW>;
        reset-gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
        hdmi-phandle = <&hdmi>;
      };
    };
+100 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
# Copyright (c) 2020 MediaTek Inc.
%YAML 1.2
---
$id: http://devicetree.org/schemas/media/i2c/dongwoon,dw9768.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Dongwoon Anatech DW9768 Voice Coil Motor (VCM) Lens Device Tree Bindings

maintainers:
  - Dongchun Zhu <dongchun.zhu@mediatek.com>

description: |-
  The Dongwoon DW9768 is a single 10-bit digital-to-analog (DAC) converter
  with 100 mA output current sink capability. VCM current is controlled with
  a linear mode driver. The DAC is controlled via a 2-wire (I2C-compatible)
  serial interface that operates at clock rates up to 1MHz. This chip
  integrates Advanced Actuator Control (AAC) technology and is intended for
  driving voice coil lenses in camera modules.

properties:
  compatible:
    enum:
      - dongwoon,dw9768 # for DW9768 VCM
      - giantec,gt9769  # for GT9769 VCM

  reg:
    maxItems: 1

  vin-supply:
    description:
      Definition of the regulator used as Digital I/O voltage supply.

  vdd-supply:
    description:
      Definition of the regulator used as Digital core voltage supply.

  dongwoon,aac-mode:
    description:
      Indication of AAC mode select.
    allOf:
      - $ref: "/schemas/types.yaml#/definitions/uint32"
      - enum:
          - 1    #  AAC2 mode(operation time# 0.48 x Tvib)
          - 2    #  AAC3 mode(operation time# 0.70 x Tvib)
          - 3    #  AAC4 mode(operation time# 0.75 x Tvib)
          - 5    #  AAC8 mode(operation time# 1.13 x Tvib)
        default: 2

  dongwoon,aac-timing:
    description:
      Number of AAC Timing count that controlled by one 6-bit period of
      vibration register AACT[5:0], the unit of which is 100 us.
    allOf:
      - $ref: "/schemas/types.yaml#/definitions/uint32"
      - default: 0x20
        minimum: 0x00
        maximum: 0x3f

  dongwoon,clock-presc:
    description:
      Indication of VCM internal clock dividing rate select, as one multiple
      factor to calculate VCM ring periodic time Tvib.
    allOf:
      - $ref: "/schemas/types.yaml#/definitions/uint32"
      - enum:
          - 0    #  Dividing Rate -  2
          - 1    #  Dividing Rate -  1
          - 2    #  Dividing Rate -  1/2
          - 3    #  Dividing Rate -  1/4
          - 4    #  Dividing Rate -  8
          - 5    #  Dividing Rate -  4
        default: 1

required:
  - compatible
  - reg
  - vin-supply
  - vdd-supply

additionalProperties: false

examples:
  - |

    i2c {
        #address-cells = <1>;
        #size-cells = <0>;

        dw9768: camera-lens@c {
            compatible = "dongwoon,dw9768";
            reg = <0x0c>;

            vin-supply = <&mt6358_vcamio_reg>;
            vdd-supply = <&mt6358_vcama2_reg>;
            dongwoon,aac-timing = <0x39>;
        };
    };

...
+159 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause
# Copyright (C) 2019 Renesas Electronics Corp.
%YAML 1.2
---
$id: http://devicetree.org/schemas/media/i2c/imi,rdacm2x-gmsl.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title:  IMI D&D RDACM20 and RDACM21 Automotive Camera Platforms

maintainers:
  - Jacopo Mondi <jacopo+renesas@jmondi.org>
  - Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
  - Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
  - Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>

description: -|
  The IMI D&D RDACM20 and RDACM21 are GMSL-compatible camera designed for
  automotive applications.

  The RDACM20 camera module encloses a Maxim Integrated MAX9271 GMSL serializer,
  coupled with an OV10635 image sensor and an embedded MCU. Both the MCU and
  the image sensor are connected to the serializer local I2C bus and are
  accessible by the host SoC by direct addressing.

  The RDACM21 camera module encloses the same serializer, coupled with an
  OV10640 image sensor and an OV490 ISP. Only the OV490 ISP is interfaced to
  the serializer local I2C bus while the image sensor is not accessible from
  the host SoC.

  They both connect to a remote GMSL endpoint through a coaxial cable.

                                                   IMI RDACM20
  +---------------+                        +--------------------------------+
  |      GMSL     |   <- Video Stream      |       <- Video--------\        |
  |               |< === GMSL Link ====== >|MAX9271<- I2C bus-> <-->OV10635 |
  | de-serializer |   <- I2C messages ->   |                   \<-->MCU     |
  +---------------+                        +--------------------------------+

                                                   IMI RDACM21
  +---------------+                        +--------------------------------+
  |      GMSL     |   <- Video Stream      |       <- Video--------\        |
  |               |< === GMSL Link ====== >|MAX9271<- I2C bus-> <-->OV490   |
  |               |   <- I2C messages ->   |                          |     |
  | de-serializer |                        |          OV10640 <-------|     |
  +---------------+                        +--------------------------------+

  Both camera modules serialize video data generated by the embedded camera
  sensor on the GMSL serial channel to a remote GMSL de-serializer. They also
  receive and transmit I2C messages encapsulated and transmitted on the GMSL
  bidirectional control channel.

  All I2C traffic received on the GMSL link not directed to the serializer is
  propagated on the local I2C bus to the remote device there connected. All the
  I2C traffic generated on the local I2C bus not directed to the serializer is
  propagated to the remote de-serializer encapsulated in the GMSL control
  channel.

  The RDACM20 and RDACM21 DT node should be a direct child of the GMSL
  deserializer's I2C bus corresponding to the GMSL link that the camera is
  attached to.

properties:
  '#address-cells':
    const: 1

  '#size-cells':
    const: 0

  compatible:
    enum:
      - imi,rdacm20
      - imi,rdacm21

  reg:
    description: -|
      I2C device addresses, the first to be assigned to the serializer, the
      following ones to be assigned to the remote devices.

      For RDACM20 the second entry of the property is assigned to the
      OV10635 image sensor and the optional third one to the embedded MCU.

      For RDACM21 the second entry is assigned to the OV490 ISP and the optional
      third one ignored.

    minItems: 2
    maxItems: 3

  port:
    type: object
    additionalProperties: false
    description: -|
      Connection to the remote GMSL endpoint are modelled using the OF graph
      bindings in accordance with the video interface bindings defined in
      Documentation/devicetree/bindings/media/video-interfaces.txt.

      The device node contains a single "port" child node with a single
      "endpoint" sub-device.

    properties:
      endpoint:
        type: object
        additionalProperties: false

        properties:
          remote-endpoint:
            description: -|
              phandle to the remote GMSL endpoint sub-node in the remote node
              port.
            maxItems: 1

        required:
          - remote-endpoint

    required:
      - endpoint

required:
  - compatible
  - reg
  - port

examples:
  - |
    i2c@e66d8000 {
      #address-cells = <1>;
      #size-cells = <0>;

      reg = <0 0xe66d8000>;

      camera@31 {
        compatible = "imi,rdacm20";
        reg = <0x31>, <0x41>, <0x51>;

        port {
          rdacm20_out0: endpoint {
            remote-endpoint = <&max9286_in0>;
          };
        };
      };
    };

  - |
    i2c@e66d8000 {
      #address-cells = <1>;
      #size-cells = <0>;

      reg = <0 0xe66d8000>;

      camera@31 {
        compatible = "imi,rdacm21";
        reg = <0x31>, <0x41>;

        port {
          rdacm21_out0: endpoint {
            remote-endpoint = <&max9286_in0>;
          };
        };
      };
    };
Loading