linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] media: dt-bindings: media: i2c: Add MT9M114 camera sensor binding
@ 2020-05-11 23:34 Laurent Pinchart
  2020-05-11 23:34 ` [PATCH 2/2] media: i2c: Add driver for On Semiconductor MT9M114 camera sensor Laurent Pinchart
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: Laurent Pinchart @ 2020-05-11 23:34 UTC (permalink / raw)
  To: linux-media; +Cc: Sakari Ailus

Add device tree binding for the ON Semiconductor MT9M114 CMOS camera
sensor.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 .../bindings/media/i2c/onnn,mt9m114.yaml      | 188 ++++++++++++++++++
 MAINTAINERS                                   |   7 +
 2 files changed, 195 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/media/i2c/onnn,mt9m114.yaml

diff --git a/Documentation/devicetree/bindings/media/i2c/onnn,mt9m114.yaml b/Documentation/devicetree/bindings/media/i2c/onnn,mt9m114.yaml
new file mode 100644
index 000000000000..2c3c691aacfd
--- /dev/null
+++ b/Documentation/devicetree/bindings/media/i2c/onnn,mt9m114.yaml
@@ -0,0 +1,188 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/media/i2c/onnn,mt9m114.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: ON Semiconductor 1/6-inch 720p CMOS Digital Image Sensor
+
+maintainers:
+  - Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+
+description: |-
+  The ON Semiconductor MT9M114 is a 1/6-inch 720p (1.26 Mp) CMOS digital image
+  sensor with an active pixel-array size of 1296H x 976V. It is programmable
+  through an I2C interface and outputs image data over a 8-bit parallel or
+  1-lane MIPI CSI-2 connection.
+
+properties:
+  compatible:
+    const: onnn,mt9m114
+
+  reg:
+    description: I2C device address
+    enum:
+      - 0x48
+      - 0x5d
+
+  clocks:
+    description: EXTCLK clock signal
+    maxItems: 1
+
+  vdd-supply:
+    description:
+      Core digital voltage supply, 1.8V
+
+  vddio-supply:
+    description:
+      I/O digital voltage supply, 1.8V or 2.8V
+
+  vaa-supply:
+    description:
+      Analog voltage supply, 2.8V
+
+  reset-gpios:
+    description: |-
+      Reference to the GPIO connected to the RESET_BAR pin, if any (active
+      low).
+
+  # See ../video-interfaces.txt for more details
+  port:
+    type: object
+    properties:
+      endpoint:
+        type: object
+        properties:
+          bus-type:
+            enum: [4, 5, 6]
+
+          clock-lanes:
+            items:
+              - const: 0
+
+          data-lanes:
+            items:
+              - const: 1
+
+          bus-width:
+            items:
+              - const: 8
+
+          hsync-active:
+            items:
+              - const: 1
+
+          vsync-active:
+            items:
+              - const: 1
+
+        required:
+          - bus-type
+
+        allOf:
+          - if:
+              properties:
+                bus-type:
+                  const: 4
+            then:
+              properties:
+                bus-width: false
+                hsync-active: false
+                vsync-active: false
+
+          - if:
+              properties:
+                bus-type:
+                  const: 5
+            then:
+              properties:
+                clock-lanes: false
+                data-lanes: false
+
+          - if:
+              properties:
+                bus-type:
+                  const: 6
+            then:
+              properties:
+                clock-lanes: false
+                data-lanes: false
+                hsync-active: false
+                vsync-active: false
+
+        unevaluatedProperties: false
+
+required:
+  - compatible
+  - reg
+  - clocks
+  - vdd-supply
+  - vddio-supply
+  - vaa-supply
+  - port
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+
+    i2c0 {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        sensor@48 {
+            compatible = "onnn,mt9m114";
+            reg = <0x48>;
+
+            clocks = <&clk24m 0>;
+
+            reset-gpios = <&gpio5 21 GPIO_ACTIVE_LOW>;
+
+            vddio-supply = <&reg_cam_1v8>;
+            vdd-supply = <&reg_cam_1v8>;
+            vaa-supply = <&reg_2p8v>;
+
+            port {
+                endpoint {
+                    bus-type = <4>;
+                    clock-lanes = <0>;
+                    data-lanes = <1>;
+                    remote-endpoint = <&mipi_csi_in>;
+                };
+            };
+        };
+    };
+
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+
+    i2c0 {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        sensor@5d {
+            compatible = "onnn,mt9m114";
+            reg = <0x5d>;
+
+            clocks = <&clk24m 0>;
+
+            reset-gpios = <&gpio5 21 GPIO_ACTIVE_LOW>;
+
+            vddio-supply = <&reg_cam_1v8>;
+            vdd-supply = <&reg_cam_1v8>;
+            vaa-supply = <&reg_2p8v>;
+
+            port {
+                endpoint {
+                    bus-type = <5>;
+                    bus-width = <8>;
+                    hsync-active = <1>;
+                    vsync-active = <1>;
+                    remote-endpoint = <&parallel_in>;
+                };
+            };
+        };
+    };
+
+...
diff --git a/MAINTAINERS b/MAINTAINERS
index 091ec22c1a23..61d2fb6d049e 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -11457,6 +11457,13 @@ T:	git git://linuxtv.org/media_tree.git
 F:	drivers/media/i2c/mt9m032.c
 F:	include/media/i2c/mt9m032.h
 
+MT9M114 ON SEMICONDUCTOR SENSOR DRIVER
+M:	Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+L:	linux-media@vger.kernel.org
+S:	Maintained
+T:	git git://linuxtv.org/media_tree.git
+F:	Documentation/devicetree/bindings/media/i2c.onnn,mt9m114.yaml
+
 MT9P031 APTINA CAMERA SENSOR
 M:	Laurent Pinchart <laurent.pinchart@ideasonboard.com>
 L:	linux-media@vger.kernel.org
-- 
Regards,

Laurent Pinchart


^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2022-02-06 21:42 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-11 23:34 [PATCH 1/2] media: dt-bindings: media: i2c: Add MT9M114 camera sensor binding Laurent Pinchart
2020-05-11 23:34 ` [PATCH 2/2] media: i2c: Add driver for On Semiconductor MT9M114 camera sensor Laurent Pinchart
2020-05-12 22:55   ` Sakari Ailus
2020-05-13  0:00     ` Laurent Pinchart
2020-05-13 11:53       ` Sakari Ailus
2020-05-13 12:36         ` Laurent Pinchart
2020-05-13 15:12           ` Sakari Ailus
2020-05-16 22:38             ` Laurent Pinchart
2022-02-06 21:41               ` Laurent Pinchart
2020-05-12  8:45 ` [PATCH 1/2] media: dt-bindings: media: i2c: Add MT9M114 camera sensor binding Sakari Ailus
2020-05-12 20:58   ` Laurent Pinchart
2020-05-12 21:31     ` Sakari Ailus
2020-05-12 21:53       ` Laurent Pinchart
2020-05-12 22:03         ` Sakari Ailus
2020-05-12 22:17           ` Laurent Pinchart
2020-05-16 14:32 ` Jacopo Mondi
2020-05-16 21:26   ` Laurent Pinchart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).