xref: /linux/Documentation/devicetree/bindings/media/i2c/mipi-ccs.yaml (revision 6e9a12f85a7567bb9a41d5230468886bd6a27b20)
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2# Copyright (C) 2014--2020 Intel Corporation
3%YAML 1.2
4---
5$id: http://devicetree.org/schemas/media/i2c/mipi-ccs.yaml#
6$schema: http://devicetree.org/meta-schemas/core.yaml#
7
8title: MIPI CCS, SMIA++ and SMIA compliant camera sensors
9
10maintainers:
11  - Sakari Ailus <sakari.ailus@linux.intel.com>
12
13description:
14
15  CCS (Camera Command Set) is a raw Bayer camera sensor standard defined by the
16  MIPI Alliance; see
17  <URL:https://www.mipi.org/specifications/camera-command-set>.
18
19  SMIA (Standard Mobile Imaging Architecture) is an image sensor standard
20  defined jointly by Nokia and ST. SMIA++, defined by Nokia, is an extension of
21  that.
22
23  More detailed documentation can be found in
24  Documentation/devicetree/bindings/media/video-interfaces.txt .
25
26allOf:
27  - $ref: /schemas/media/video-interface-devices.yaml#
28
29properties:
30  compatible:
31    oneOf:
32      - items:
33          - const: mipi-ccs-1.1
34          - const: mipi-ccs
35      - items:
36          - const: mipi-ccs-1.0
37          - const: mipi-ccs
38      - const: nokia,smia
39
40  reg:
41    maxItems: 1
42
43  vana-supply:
44    description: Analogue voltage supply (VANA), sensor dependent.
45
46  vcore-supply:
47    description: Core voltage supply (VCore), sensor dependent.
48
49  vio-supply:
50    description: I/O voltage supply (VIO), sensor dependent.
51
52  clocks:
53    description: External clock to the sensor.
54    maxItems: 1
55
56  clock-frequency:
57    description: Frequency of the external clock to the sensor in Hz.
58
59  reset-gpios:
60    description: Reset GPIO. Also commonly called XSHUTDOWN in hardware
61      documentation.
62    maxItems: 1
63
64  flash-leds: true
65  lens-focus: true
66
67  rotation:
68    enum: [ 0, 180 ]
69
70  port:
71    $ref: /schemas/graph.yaml#/$defs/port-base
72    additionalProperties: false
73
74    properties:
75      endpoint:
76        $ref: /schemas/media/video-interfaces.yaml#
77        unevaluatedProperties: false
78
79        properties:
80          link-frequencies: true
81          data-lanes: true
82          bus-type:
83            enum:
84              - 1 # CSI-2 C-PHY
85              - 3 # CCP2
86              - 4 # CSI-2 D-PHY
87
88        required:
89          - link-frequencies
90          - data-lanes
91          - bus-type
92
93required:
94  - compatible
95  - reg
96  - clock-frequency
97  - clocks
98
99additionalProperties: false
100
101examples:
102  - |
103    #include <dt-bindings/gpio/gpio.h>
104    #include <dt-bindings/media/video-interfaces.h>
105
106    i2c {
107        #address-cells = <1>;
108        #size-cells = <0>;
109
110        clock-frequency = <400000>;
111
112        camera-sensor@10 {
113            compatible = "mipi-ccs-1.0", "mipi-ccs";
114            reg = <0x10>;
115            reset-gpios = <&gpio3 20 GPIO_ACTIVE_LOW>;
116            vana-supply = <&vaux3>;
117            clocks = <&omap3_isp 0>;
118            clock-frequency = <9600000>;
119            port {
120                ccs_ep: endpoint {
121                    data-lanes = <1 2>;
122                    remote-endpoint = <&csi2a_ep>;
123                    link-frequencies = /bits/ 64 <199200000 210000000
124                                                  499200000>;
125                    bus-type = <MEDIA_BUS_TYPE_CSI2_DPHY>;
126                };
127            };
128        };
129    };
130...
131