blob: b8156c379ed7c372aef38cfacf9517127c173099 [file] [log] [blame]
Kevin Chan472c7dd2012-08-01 14:08:52 -07001* Qualcomm MSM CCI
2
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -07003[First level nodes]
Kevin Chan472c7dd2012-08-01 14:08:52 -07004Required properties:
5- cell-index: cci hardware core index
6- compatible :
7 - "qcom,cci"
8- reg : offset and length of the register set for the device
9 for the cci operating in compatible mode.
10- reg-names : should specify relevant names to each reg property defined.
11- interrupts : should contain the cci interrupt.
12- interrupt-names : should specify relevant names to each interrupts
13 property defined.
Shuzhen Wang77337992013-01-08 15:46:09 -080014- gpios : should contain phandle to gpio controller node and array of
15 #gpio-cells specifying specific gpio (controller specific)
16- qcom,gpio-req-tbl-num : should contain index to gpios specific to this sensor
17- qcom,gpio-req-tbl-flags : should contain direction of gpios present in
18 qcom,gpio-req-tbl-num property (in the same order)
19- qcom,gpio-req-tbl-label : should contain name of gpios present in
20 qcom,gpio-req-tbl-num property (in the same order)
Vasko Kalanoski18ba0d42013-04-15 21:18:54 -070021
22Optional properties:
23- master0: qcom,cci-master0 - node should contain clock settings for
24 cci master 0 bus
25- master1: qcom,cci-master1 - node should contain clock settings for
26 cci master 1 bus
27
28[Second level nodes]
29* Qualcomm CCI clock settings
30
31Optional properties:
Shuzhen Wang77337992013-01-08 15:46:09 -080032- qcom,hw-thigh : should contain high period of the SCL clock in terms of CCI
33 clock cycle
34- qcom,hw-tlow : should contain high period of the SCL clock in terms of CCI
35 clock cycle
36- qcom,hw-tsu-sto : should contain setup time for STOP condition
37- qcom,hw-tsu-sta : should contain setup time for Repeated START condition
38- qcom,hw-thd-dat : should contain hold time for the data
39- qcom,hw-thd-sta : should contain hold time for START condition
40- qcom,hw-tbuf : should contain free time between a STOP and a START condition
41- qcom,hw-scl-stretch-en : should contain enable or disable clock stretching
42- qcom,hw-trdhld : should contain internal hold time for SDA
43- qcom,hw-tsp : should contain filtering of glitches
Kevin Chan472c7dd2012-08-01 14:08:52 -070044
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070045* Qualcomm MSM Sensor
46
47MSM sensor node contains properties of camera sensor
48
49Required properties:
Li Sun4c6a4e62013-06-20 07:37:48 +080050- compatible : should be manufacturer name followed by sensor name
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070051 - "qcom,s5k3l1yx"
Li Sun4c6a4e62013-06-20 07:37:48 +080052 - "shinetech,gc0339"
Li Sun3eb82a62013-06-14 15:14:22 +080053 - "shinetech,hi256"
Yu Yang8744be82013-06-18 14:39:37 +080054 - "shinetech,s5k4e1"
Sreesudhan Ramakrish Ramkumar78892ea2013-02-21 00:59:37 -080055- reg : should contain i2c slave address of the device
Shuzhen Wang77337992013-01-08 15:46:09 -080056- qcom,slave-id : should contain i2c slave address, device id address
57 and expected id read value
58- qcom,csiphy-sd-index : should contain csiphy instance that will used to
59 receive sensor data
60 - 0, 1, 2
61- qcom,csid-sd-index : should contain csid core instance that will used to
62 receive sensor data
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070063 - 0, 1, 2, 3
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070064- qcom,sensor-name : should contain unique sensor name to differentiate from
65 other sensor
66 - "s5k3l1yx"
67- cam_vdig-supply : should contain regulator from which digital voltage is
68 supplied
69- cam_vana-supply : should contain regulator from which analog voltage is
70 supplied
71- cam_vio-supply : should contain regulator from which IO voltage is supplied
72- qcom,cam-vreg-name : should contain names of all regulators needed by this
73 sensor
74 - "cam_vdig", "cam_vana", "cam_vio", "cam_vaf"
75- qcom,cam-vreg-type : should contain regulator type for regulators mentioned in
76 qcom,cam-vreg-name property (in the same order)
77 - 0 for LDO and 1 for LVS
78- qcom,cam-vreg-min-voltage : should contain minimum voltage level for
79 regulators mentioned in qcom,cam-vreg-name property (in the same order)
80- qcom,cam-vreg-max-voltage : should contain maximum voltage level for
81 regulators mentioned in qcom,cam-vreg-name property (in the same order)
82- qcom,cam-vreg-op-mode : should contain optimum voltage level for regulators
83 mentioned in qcom,cam-vreg-name property (in the same order)
Shuzhen Wang77337992013-01-08 15:46:09 -080084- qcom,sensor-mode : should contain sensor mode supported
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070085 - 0 -> back camera 2D
86 - 1 -> front camera 2D
87 - 2 -> back camera 3D
88 - 3 -> back camera int 3D
89- qcom,sensor-type : should contain format of data that sensor streams
90 - 0 -> bayer format
91 - 1 -> yuv format
92
93Optional properties:
Shuzhen Wang77337992013-01-08 15:46:09 -080094- qcom,is-vpe : should be enabled if VPE module is required for post processing
95 of this sensor
96 - 1 if required, 0 otherwise
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -070097- qcom,mount-angle : should contain the physical mount angle of the sensor on
98 the target
99 - 0, 90, 180, 360
100- qcom,gpio-no-mux : should contain field to indicate whether gpio mux table is
101 available
102 - 1 if gpio mux is not available, 0 otherwise
103- cam_vaf-supply : should contain regulator from which AF voltage is supplied
104- gpios : should contain phandle to gpio controller node and array of
105 #gpio-cells specifying specific gpio (controller specific)
Shuzhen Wang77337992013-01-08 15:46:09 -0800106- qcom,gpio-reset : should contain index to gpio used by sensors reset_n
Jeyaprakash Soundrapandiana6be88e2013-05-10 18:40:58 -0700107- qcom,gpio-standby : should contain index to gpio used by sensors standby_n
feim1b0083f2013-06-05 09:09:44 +0800108- qcom,gpio-vio : should contain index to gpio used by sensors io vreg enable
109- qcom,gpio-vana : should contain index to gpio used by sensors analog vreg enable
110- qcom,gpio-vdig : should contain index to gpio used by sensors digital vreg enable
111- qcom,gpio-vaf : should contain index to gpio used by sensors af vreg enable
112- qcom,gpio-af-pwdm : should contain index to gpio used by sensors af pwdm_n
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700113- qcom,gpio-req-tbl-num : should contain index to gpios specific to this sensor
114- qcom,gpio-req-tbl-flags : should contain direction of gpios present in
115 qcom,gpio-req-tbl-num property (in the same order)
116- qcom,gpio-req-tbl-label : should contain name of gpios present in
117 qcom,gpio-req-tbl-num property (in the same order)
118- qcom,gpio-set-tbl-num : should contain index of gpios that need to be
119 configured by msm
120- qcom,gpio-set-tbl-flags : should contain value to be configured for the gpios
121 present in qcom,gpio-set-tbl-num property (in the same order)
122- qcom,gpio-set-tbl-delay : should contain amount of delay after configuring
123 gpios as specified in gpio_set_tbl_flags property (in the same order)
124- qcom,csi-lane-assign : should contain lane assignment value to map CSIPHY
125 lanes to CSID lanes
126 - 0x4320
127- qcom,csi-lane-mask : should contain lane mask that specifies CSIPHY lanes to
128 be enabled
129- qcom,csi-phy-sel : should contain CSIPHY core instance from which CSID should
130 receive data
131- qcom,actuator-cam-name : should contain actuator cam name associated with
132 this sensor
133 - If actuator does not exist, this property should not be initialized
134 - If actuator exist, this field should indicate the index of actuator to
135 be used
136- qcom,actuator-vcm-pwd : should contain the gpio pin of vcm power to be enabled
137 for actuator
138- qcom,actuator-vcm-enable : should contain value to be set for actuator vcm
139 gpio
Shuzhen Wang77337992013-01-08 15:46:09 -0800140- qcom,sensor-position : should contain the mount angle of the camera sensor
141 - 0 -> back camera
142 - 1 -> front camera
Sreesudhan Ramakrish Ramkumar9f3aa302013-01-23 14:50:58 -0800143- qcom,cci-master : should contain i2c master id to be used for this camera
144 sensor
145 - 0 -> MASTER 0
146 - 1 -> MASTER 1
Sreesudhan Ramakrish Ramkumarf61a5092013-01-26 21:33:01 -0800147- qcom,actuator-src : if auto focus is supported by this sensor, this
148 property should contain phandle of respective actuator node
Sreesudhan Ramakrish Ramkumar055c60e2013-02-19 01:00:42 -0800149- qcom,led-flash-src : if LED flash is supported by this sensor, this
150 property should contain phandle of respective LED flash node
Sreesudhan Ramakrish Ramkumar9a268c82013-05-23 15:28:00 -0700151- qcom,vdd-cx-supply : should contain regulator from which cx voltage is
152 supplied
153- qcom,vdd-cx-name : should contain names of cx regulator
154
Sreesudhan Ramakrish Ramkumar6acf6252013-01-26 21:26:13 -0800155* Qualcomm MSM ACTUATOR
156
157Required properties:
158- cell-index : should contain unique identifier to differentiate
159 between multiple actuators
160- reg : should contain i2c slave address of the actuator and length of
161 data field which is 0x0
162- compatible :
163 - "qcom,actuator"
164- qcom,cci-master : should contain i2c master id to be used for this camera
165 sensor
166 - 0 -> MASTER 0
167 - 1 -> MASTER 1
168
Kevin Chan472c7dd2012-08-01 14:08:52 -0700169Example:
170
171 qcom,cci@0xfda0c000 {
172 cell-index = <0>;
173 compatible = "qcom,cci";
174 reg = <0xfda0c000 0x300>;
175 reg-names = "cci";
176 interrupts = <0 50 0>;
177 interrupt-names = "cci";
Shuzhen Wang77337992013-01-08 15:46:09 -0800178 gpios = <&msmgpio 19 0>,
179 <&msmgpio 20 0>,
180 <&msmgpio 21 0>,
181 <&msmgpio 22 0>;
182 qcom,gpio-tbl-num = <0 1 2 3>;
183 qcom,gpio-tbl-flags = <1 1 1 1>;
184 qcom,gpio-tbl-label = "CCI_I2C_DATA0",
185 "CCI_I2C_CLK0",
186 "CCI_I2C_DATA1",
187 "CCI_I2C_CLK1";
Vasko Kalanoski18ba0d42013-04-15 21:18:54 -0700188 master0: qcom,cci-master0 {
189 status = "disabled";
190 };
191 master1: qcom,cci-master1 {
192 status = "disabled";
193 };
Sreesudhan Ramakrish Ramkumar6acf6252013-01-26 21:26:13 -0800194
195 actuator0: qcom,actuator@18 {
196 cell-index = <0>;
Sreesudhan Ramakrish Ramkumar78892ea2013-02-21 00:59:37 -0800197 reg = <0x18>;
Sreesudhan Ramakrish Ramkumar6acf6252013-01-26 21:26:13 -0800198 compatible = "qcom,actuator";
199 qcom,cci-master = <0>;
200 };
201
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700202 qcom,s5k3l1yx@6e {
203 compatible = "qcom,s5k3l1yx";
Sreesudhan Ramakrish Ramkumar78892ea2013-02-21 00:59:37 -0800204 reg = <0x6e>;
Shuzhen Wang77337992013-01-08 15:46:09 -0800205 qcom,slave-id = <0x6e 0x0 0x3121>;
Shuzhen Wang77337992013-01-08 15:46:09 -0800206 qcom,csiphy-sd-index = <2>;
207 qcom,csid-sd-index = <0>;
Sreesudhan Ramakrish Ramkumarf61a5092013-01-26 21:33:01 -0800208 qcom,actuator-src = <&actuator0>;
Sreesudhan Ramakrish Ramkumar055c60e2013-02-19 01:00:42 -0800209 qcom,led-flash-src = <&led_flash0>;
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700210 qcom,mount-angle = <90>;
211 qcom,sensor-name = "s5k3l1yx";
Hody Hunga86d97a2013-05-09 17:03:19 -0700212 qcom,vdd-cx-supply = <&pm8841_s2>;
213 qcom,vdd-cx-name = "qcom,vdd-cx";
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700214 cam_vdig-supply = <&pm8941_l3>;
215 cam_vana-supply = <&pm8941_l17>;
216 cam_vio-supply = <&pm8941_lvs3>;
217 cam_vaf-supply = <&pm8941_l23>;
218 qcom,cam-vreg-name = "cam_vdig", "cam_vana", "cam_vio", "cam_vaf";
219 qcom,cam-vreg-type = <0 0 1 0>;
220 qcom,cam-vreg-min-voltage = <1225000 2850000 0 3000000>;
221 qcom,cam-vreg-max-voltage = <1225000 2850000 0 3000000>;
222 qcom,cam-vreg-op-mode = <105000 80000 0 100000>;
223 qcom,gpio-no-mux = <0>;
224 gpios = <&msmgpio 15 0>,
Jeyaprakash Soundrapandiana6be88e2013-05-10 18:40:58 -0700225 <&msmgpio 90 0>,
226 <&msmgpio 89 0>;
Shuzhen Wang77337992013-01-08 15:46:09 -0800227 qcom,gpio-reset = <1>;
Jeyaprakash Soundrapandiana6be88e2013-05-10 18:40:58 -0700228 qcom,gpio-standby = <2>;
229 qcom,gpio-req-tbl-num = <0 1 2>;
230 qcom,gpio-req-tbl-flags = <1 0 0>;
Shuzhen Wang77337992013-01-08 15:46:09 -0800231 qcom,gpio-req-tbl-label = "CAMIF_MCLK",
Jeyaprakash Soundrapandiana6be88e2013-05-10 18:40:58 -0700232 "CAM_RESET1",
233 "CAM_STANDBY";
Shuzhen Wang77337992013-01-08 15:46:09 -0800234 qcom,gpio-set-tbl-num = <1 1>;
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700235 qcom,gpio-set-tbl-flags = <0 2>;
236 qcom,gpio-set-tbl-delay = <1000 4000>;
237 qcom,csi-lane-assign = <0x4320>;
238 qcom,csi-lane-mask = <0x1F>;
239 qcom,csi-phy-sel = <0>;
Shuzhen Wang77337992013-01-08 15:46:09 -0800240 qcom,sensor-position = <0>;
241 qcom,sensor-mode = <1>;
Sreesudhan Ramakrish Ramkumar834e9962012-09-07 13:03:10 -0700242 };
Kevin Chan472c7dd2012-08-01 14:08:52 -0700243 };
Vasko Kalanoski18ba0d42013-04-15 21:18:54 -0700244
245 &master0 {
246 qcom,hw-thigh = <78>;
247 qcom,hw-tlow = <114>;
248 qcom,hw-tsu-sto = <28>;
249 qcom,hw-tsu-sta = <28>;
250 qcom,hw-thd-dat = <10>;
251 qcom,hw-thd-sta = <77>;
252 qcom,hw-tbuf = <118>;
253 qcom,hw-scl-stretch-en = <0>;
254 qcom,hw-trdhld = <6>;
255 qcom,hw-tsp = <1>;
256 status = "ok";
257 };
258
259 &master1 {
260 qcom,hw-thigh = <78>;
261 qcom,hw-tlow = <114>;
262 qcom,hw-tsu-sto = <28>;
263 qcom,hw-tsu-sta = <28>;
264 qcom,hw-thd-dat = <10>;
265 qcom,hw-thd-sta = <77>;
266 qcom,hw-tbuf = <118>;
267 qcom,hw-scl-stretch-en = <0>;
268 qcom,hw-trdhld = <6>;
269 qcom,hw-tsp = <1>;
270 status = "ok";
271 };