new file mode 100644
@@ -0,0 +1,162 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/media/i2c/onnn,ar0144.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: ON Semiconductor AR0144 MIPI CSI-2 sensor
+
+maintainers:
+ - Krzysztof Hałasa <khalasa@piap.pl>
+
+description: |
+ The AR0144 is a 1/4" 1MP raw CMOS image sensor with MIPI CSI-2 and parallel
+ outputs, and an I2C-compatible control interface.
+
+ The sensor comes in a regular CMOS version (AR0144CS) and an automotive
+ version (AR0144AT). The former is further declined in a colour version
+ (AR0144CSSC) and a monochrome version (AR0144CSSM), while the later exists
+ only in monochrome (AR0144ATSM)
+
+allOf:
+ - $ref: /schemas/media/video-interface-devices.yaml#
+
+properties:
+ compatible:
+ enum:
+ - onnn,ar0144c # Color version
+ - onnn,ar0144m # Monochrome version
+
+ reg:
+ maxItems: 1
+
+ clocks:
+ maxItems: 1
+
+ vaa-supply:
+ description:
+ Supply for the VAA and VAA_PIX analog power rails (2.8V).
+
+ vdd-supply:
+ description:
+ Supply for the VDD and VDD_PHY digital power rails (1.2V).
+
+ vddio-supply:
+ description:
+ Supply for the VDD_IO digital I/O power rail (1.8V or 2.8V).
+
+ reset-gpios:
+ description: Reset GPIO, active low.
+ maxItems: 1
+
+ port:
+ $ref: /schemas/graph.yaml#/$defs/port-base
+ unevaluatedProperties: false
+ description:
+ Video output port.
+
+ properties:
+ endpoint:
+ $ref: /schemas/media/video-interfaces.yaml#
+ unevaluatedProperties: false
+
+ properties:
+ bus-type:
+ enum:
+ - 4 # MEDIA_BUS_TYPE_CSI2_DPHY
+ - 5 # MEDIA_BUS_TYPE_PARALLEL
+
+ data-lanes:
+ items:
+ - const: 1
+ - const: 2
+
+ bus-width:
+ enum: [8, 10, 12]
+ default: 12
+
+ data-shift:
+ enum: [0, 2, 4]
+ default: 0
+
+ pclk-sample:
+ enum: [0, 1]
+ default: 0
+
+ allOf:
+ - if:
+ properties:
+ bus-type:
+ const: 4 # MEDIA_BUS_TYPE_CSI2_DPHY
+ then:
+ properties:
+ bus-width: false
+ data-shift: false
+ pclk-sample: false
+ required:
+ - data-lanes
+ else:
+ properties:
+ data-lanes: false
+ - if:
+ properties:
+ bus-width:
+ const: 10
+ then:
+ properties:
+ data-shift:
+ enum: [0, 2]
+ - if:
+ properties:
+ bus-width:
+ const: 12
+ then:
+ properties:
+ data-shift:
+ const: 0
+
+ required:
+ - bus-type
+
+required:
+ - compatible
+ - reg
+ - clocks
+ - clock-names
+ - vaa-supply
+ - vdd-supply
+ - vddio-supply
+ - port
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/gpio/gpio.h>
+ #include <dt-bindings/media/video-interfaces.h>
+
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ camera@10 {
+ compatible = "onnn,ar0144c";
+ reg = <0x10>;
+
+ clocks = <&cam_clk>;
+
+ reset-gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+
+ vaa-supply = <®_2v8>;
+ vdd-supply = <®_1v2>;
+ vddio-supply = <®_1v8>;
+
+ port {
+ ar0144_out: endpoint {
+ remote-endpoint = <&mipi_csi2_in>;
+ bus-type = <MEDIA_BUS_TYPE_CSI2_DPHY>;
+ data-lanes = <1 2>;
+ };
+ };
+ };
+ };
@@ -1650,6 +1650,12 @@ S: Supported
W: http://www.aquantia.com
F: drivers/net/ethernet/aquantia/atlantic/aq_ptp*
+AR0144 ONSEMI CAMERA SENSOR DRIVER
+M: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+L: linux-media@vger.kernel.org
+S: Maintained
+F: Documentation/devicetree/bindings/media/i2c/onnn,ar0144.yaml
+
AR0521 ON SEMICONDUCTOR CAMERA SENSOR DRIVER
M: Krzysztof Hałasa <khalasa@piap.pl>
L: linux-media@vger.kernel.org
Add device tree binding for the onsemi AR0144 CMOS camera sensor. The binding supports both the monochrome and color sensor versions. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> --- Changes since v1: - Drop clock-names - Rename vdd_io-supply to vddio supply - Drop unnecessary | --- .../bindings/media/i2c/onnn,ar0144.yaml | 162 ++++++++++++++++++ MAINTAINERS | 6 + 2 files changed, 168 insertions(+) create mode 100644 Documentation/devicetree/bindings/media/i2c/onnn,ar0144.yaml