1// SPDX-License-Identifier: GPL-2.0-only
2
3/dts-v1/;
4
5#include "msm8916-pm8916.dtsi"
6#include <dt-bindings/gpio/gpio.h>
7#include <dt-bindings/input/input.h>
8#include <dt-bindings/interrupt-controller/irq.h>
9
10/ {
11	model = "Asus Zenfone 2 Laser";
12	compatible = "asus,z00l", "qcom,msm8916";
13	chassis-type = "handset";
14
15	aliases {
16		serial0 = &blsp1_uart2;
17	};
18
19	chosen {
20		stdout-path = "serial0";
21	};
22
23	gpio-keys {
24		compatible = "gpio-keys";
25
26		pinctrl-names = "default";
27		pinctrl-0 = <&gpio_keys_default>;
28
29		label = "GPIO Buttons";
30
31		button-volume-up {
32			label = "Volume Up";
33			gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
34			linux,code = <KEY_VOLUMEUP>;
35			debounce-interval = <15>;
36		};
37
38		button-volume-down {
39			label = "Volume Down";
40			gpios = <&msmgpio 117 GPIO_ACTIVE_LOW>;
41			linux,code = <KEY_VOLUMEDOWN>;
42			debounce-interval = <15>;
43		};
44	};
45
46	reg_sd_vmmc: regulator-sdcard-vmmc {
47		compatible = "regulator-fixed";
48		regulator-name = "sdcard-vmmc";
49		regulator-min-microvolt = <2950000>;
50		regulator-max-microvolt = <2950000>;
51
52		gpio = <&msmgpio 87 GPIO_ACTIVE_HIGH>;
53		enable-active-high;
54
55		startup-delay-us = <200>;
56
57		pinctrl-names = "default";
58		pinctrl-0 = <&sd_vmmc_en_default>;
59	};
60
61	usb_id: usb-id {
62		compatible = "linux,extcon-usb-gpio";
63		id-gpios = <&msmgpio 110 GPIO_ACTIVE_HIGH>;
64		pinctrl-names = "default";
65		pinctrl-0 = <&usb_id_default>;
66	};
67};
68
69&blsp_i2c2 {
70	status = "okay";
71
72	magnetometer@c {
73		compatible = "asahi-kasei,ak09911";
74		reg = <0x0c>;
75
76		vdd-supply = <&pm8916_l8>;
77		vid-supply = <&pm8916_l6>;
78
79		reset-gpios = <&msmgpio 112 GPIO_ACTIVE_LOW>;
80
81		pinctrl-names = "default";
82		pinctrl-0 = <&mag_reset_default>;
83	};
84
85	imu@68 {
86		compatible = "invensense,mpu6515";
87		reg = <0x68>;
88
89		interrupt-parent = <&msmgpio>;
90		interrupts = <36 IRQ_TYPE_EDGE_RISING>;
91
92		vdd-supply = <&pm8916_l17>;
93		vddio-supply = <&pm8916_l6>;
94
95		pinctrl-names = "default";
96		pinctrl-0 = <&imu_default>;
97
98		mount-matrix = "1",  "0", "0",
99			       "0", "-1", "0",
100			       "0",  "0", "1";
101	};
102};
103
104&blsp_i2c5 {
105	status = "okay";
106
107	touchscreen@38 {
108		compatible = "edt,edt-ft5306";
109		reg = <0x38>;
110
111		interrupt-parent = <&msmgpio>;
112		interrupts = <13 IRQ_TYPE_EDGE_FALLING>;
113
114		reset-gpios = <&msmgpio 12 GPIO_ACTIVE_LOW>;
115
116		vcc-supply = <&pm8916_l11>;
117		iovcc-supply = <&pm8916_l6>;
118
119		touchscreen-size-x = <720>;
120		touchscreen-size-y = <1280>;
121
122		pinctrl-names = "default";
123		pinctrl-0 = <&touchscreen_default>;
124	};
125};
126
127&blsp1_uart2 {
128	status = "okay";
129};
130
131&sdhc_1 {
132	status = "okay";
133
134	pinctrl-names = "default", "sleep";
135	pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>;
136	pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>;
137};
138
139&sdhc_2 {
140	status = "okay";
141	vmmc-supply = <&reg_sd_vmmc>;
142
143	pinctrl-names = "default", "sleep";
144	pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd_on>;
145	pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off &sdc2_cd_off>;
146	cd-gpios = <&msmgpio 38 GPIO_ACTIVE_LOW>;
147};
148
149&usb {
150	status = "okay";
151	extcon = <&usb_id>, <&usb_id>;
152};
153
154&usb_hs_phy {
155	extcon = <&usb_id>;
156};
157
158&wcnss {
159	status = "okay";
160};
161
162&wcnss_iris {
163	compatible = "qcom,wcn3620";
164};
165
166&smd_rpm_regulators {
167	vdd_l1_l2_l3-supply = <&pm8916_s3>;
168	vdd_l4_l5_l6-supply = <&pm8916_s4>;
169	vdd_l7-supply = <&pm8916_s4>;
170
171	s3 {
172		regulator-min-microvolt = <1200000>;
173		regulator-max-microvolt = <1300000>;
174	};
175
176	s4 {
177		regulator-min-microvolt = <1800000>;
178		regulator-max-microvolt = <2100000>;
179	};
180
181	l1 {
182		regulator-min-microvolt = <1225000>;
183		regulator-max-microvolt = <1225000>;
184	};
185
186	l2 {
187		regulator-min-microvolt = <1200000>;
188		regulator-max-microvolt = <1200000>;
189	};
190
191	l4 {
192		regulator-min-microvolt = <2050000>;
193		regulator-max-microvolt = <2050000>;
194	};
195
196	l5 {
197		regulator-min-microvolt = <1800000>;
198		regulator-max-microvolt = <1800000>;
199	};
200
201	l6 {
202		regulator-min-microvolt = <1800000>;
203		regulator-max-microvolt = <1800000>;
204	};
205
206	l7 {
207		regulator-min-microvolt = <1800000>;
208		regulator-max-microvolt = <1800000>;
209	};
210
211	l8 {
212		regulator-min-microvolt = <2850000>;
213		regulator-max-microvolt = <2900000>;
214	};
215
216	l9 {
217		regulator-min-microvolt = <3300000>;
218		regulator-max-microvolt = <3300000>;
219	};
220
221	l10 {
222		regulator-min-microvolt = <2700000>;
223		regulator-max-microvolt = <2800000>;
224	};
225
226	l11 {
227		regulator-min-microvolt = <1800000>;
228		regulator-max-microvolt = <2950000>;
229		regulator-allow-set-load;
230		regulator-system-load = <200000>;
231	};
232
233	l12 {
234		regulator-min-microvolt = <1800000>;
235		regulator-max-microvolt = <2950000>;
236	};
237
238	l13 {
239		regulator-min-microvolt = <3075000>;
240		regulator-max-microvolt = <3075000>;
241	};
242
243	l14 {
244		regulator-min-microvolt = <1800000>;
245		regulator-max-microvolt = <3300000>;
246	};
247
248	l15 {
249		regulator-min-microvolt = <1800000>;
250		regulator-max-microvolt = <3300000>;
251	};
252
253	l16 {
254		regulator-min-microvolt = <1800000>;
255		regulator-max-microvolt = <3300000>;
256	};
257
258	l17 {
259		regulator-min-microvolt = <2850000>;
260		regulator-max-microvolt = <2850000>;
261	};
262
263	l18 {
264		regulator-min-microvolt = <2700000>;
265		regulator-max-microvolt = <2700000>;
266	};
267};
268
269&msmgpio {
270	gpio_keys_default: gpio-keys-default-state {
271		pins = "gpio107", "gpio117";
272		function = "gpio";
273
274		drive-strength = <2>;
275		bias-pull-up;
276	};
277
278	imu_default: imu-default-state {
279		pins = "gpio36";
280		function = "gpio";
281
282		drive-strength = <2>;
283		bias-disable;
284	};
285
286	mag_reset_default: mag-reset-default-state {
287		pins = "gpio112";
288		function = "gpio";
289
290		drive-strength = <2>;
291		bias-disable;
292	};
293
294	sd_vmmc_en_default: sd-vmmc-en-default-state {
295		pins = "gpio87";
296		function = "gpio";
297
298		drive-strength = <2>;
299		bias-disable;
300	};
301
302	touchscreen_default: touchscreen-default-state {
303		touch-pins {
304			pins = "gpio13";
305			function = "gpio";
306
307			drive-strength = <2>;
308			bias-pull-up;
309		};
310
311		reset-pins {
312			pins = "gpio12";
313			function = "gpio";
314
315			drive-strength = <2>;
316			bias-disable;
317		};
318	};
319
320	usb_id_default: usb-id-default-state {
321		pins = "gpio110";
322		function = "gpio";
323
324		drive-strength = <8>;
325		bias-pull-up;
326	};
327};
328