1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/media/i2c/hynix,hi846.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: SK Hynix Hi-846 1/4" 8M Pixel MIPI CSI-2 sensor
8
9maintainers:
10  - Martin Kepplinger <martin.kepplinger@puri.sm>
11
12description: |-
13  The Hi-846 is a raw image sensor with an MIPI CSI-2 image data
14  interface and CCI (I2C compatible) control bus. The output format
15  is raw Bayer.
16
17properties:
18  compatible:
19    const: hynix,hi846
20
21  reg:
22    maxItems: 1
23
24  clocks:
25    items:
26      - description: Reference to the mclk clock.
27
28  assigned-clocks:
29    maxItems: 1
30
31  assigned-clock-rates:
32    maxItems: 1
33
34  reset-gpios:
35    description: Reference to the GPIO connected to the RESETB pin. Active low.
36    maxItems: 1
37
38  shutdown-gpios:
39    description: Reference to the GPIO connected to the XSHUTDOWN pin. Active low.
40    maxItems: 1
41
42  vddio-supply:
43    description: Definition of the regulator used for the VDDIO power supply.
44
45  vdda-supply:
46    description: Definition of the regulator used for the VDDA power supply.
47
48  vddd-supply:
49    description: Definition of the regulator used for the VDDD power supply.
50
51  port:
52    $ref: /schemas/graph.yaml#/$defs/port-base
53    unevaluatedProperties: false
54
55    properties:
56      endpoint:
57        $ref: /schemas/media/video-interfaces.yaml#
58        unevaluatedProperties: false
59
60        properties:
61          data-lanes:
62            oneOf:
63              - items:
64                  - const: 1
65                  - const: 2
66                  - const: 3
67                  - const: 4
68              - items:
69                  - const: 1
70                  - const: 2
71
72        required:
73          - data-lanes
74
75required:
76  - compatible
77  - reg
78  - clocks
79  - assigned-clocks
80  - assigned-clock-rates
81  - vddio-supply
82  - vdda-supply
83  - vddd-supply
84  - port
85
86additionalProperties: false
87
88examples:
89  - |
90    #include <dt-bindings/gpio/gpio.h>
91
92    i2c {
93        #address-cells = <1>;
94        #size-cells = <0>;
95
96        hi846: camera@20 {
97            compatible = "hynix,hi846";
98            reg = <0x20>;
99            pinctrl-names = "default";
100            pinctrl-0 = <&pinctrl_csi1>;
101            clocks = <&clk 0>;
102            assigned-clocks = <&clk 0>;
103            assigned-clock-rates = <25000000>;
104            vdda-supply = <&reg_camera_vdda>;
105            vddd-supply = <&reg_camera_vddd>;
106            vddio-supply = <&reg_camera_vddio>;
107            reset-gpios = <&gpio1 25 GPIO_ACTIVE_LOW>;
108            shutdown-gpios = <&gpio5 4 GPIO_ACTIVE_LOW>;
109
110            port {
111                camera_out: endpoint {
112                    remote-endpoint = <&csi1_ep1>;
113                    link-frequencies = /bits/ 64
114                        <80000000 200000000>;
115                    data-lanes = <1 2>;
116                };
117            };
118        };
119    };
120
121...
122