1 // SPDX-License-Identifier: GPL-2.0
2 /dts-v1/;
3 
4 #include <dt-bindings/input/input.h>
5 #include "tegra114.dtsi"
6 
7 / {
8 	model = "Tegra Note 7";
9 	compatible = "nvidia,tn7", "nvidia,tegra114";
10 
11 	chosen {
12 		/* TN7's bootloader's arguments need to be overridden */
13 		bootargs = "console=ttyS0,115200n8 console=tty1 gpt fbcon=rotate:2";
14 		/* TN7's bootloader will place initrd at this address */
15 		linux,initrd-start = <0x82000000>;
16 		linux,initrd-end = <0x82800000>;
17 	};
18 
19 	aliases {
20 		serial0 = &uartd;
21 	};
22 
23 	firmware {
24 		trusted-foundations {
25 			compatible = "tlm,trusted-foundations";
26 			tlm,version-major = <2>;
27 			tlm,version-minor = <8>;
28 		};
29 	};
30 
31 	memory@80000000 {
32 		/* memory >= 0x37e00000 is reserved for firmware usage */
33 		reg = <0x80000000 0x37e00000>;
34 	};
35 
36 	host1x@50000000 {
37 		dsi@54300000 {
38 			status = "okay";
39 
40 			avdd-dsi-csi-supply = <&vdd_1v2_ap>;
41 
42 			panel@0 {
43 				compatible = "lg,ld070wx3-sl01";
44 				reg = <0>;
45 
46 				power-supply = <&vdd_lcd>;
47 				backlight = <&backlight>;
48 			};
49 		};
50 	};
51 
52 	serial@70006300 {
53 		/delete-property/ dmas;
54 		/delete-property/ dma-names;
55 		status = "okay";
56 	};
57 
58 	pwm@7000a000 {
59 		status = "okay";
60 	};
61 
62 	i2c@7000d000 {
63 		status = "okay";
64 		clock-frequency = <400000>;
65 
66 		palmas: pmic@58 {
67 			compatible = "ti,tps65913", "ti,palmas";
68 			reg = <0x58>;
69 			interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>;
70 
71 			#interrupt-cells = <2>;
72 			interrupt-controller;
73 
74 			ti,system-power-controller;
75 
76 			palmas_gpio: gpio {
77 				compatible = "ti,palmas-gpio";
78 				gpio-controller;
79 				#gpio-cells = <2>;
80 			};
81 
82 			pmic {
83 				compatible = "ti,tps65913-pmic", "ti,palmas-pmic";
84 
85 				ldoln-in-supply = <&vdd_smps10_out2>;
86 
87 				regulators {
88 					smps123 {
89 						regulator-name = "vd-cpu";
90 						regulator-min-microvolt = <1000000>;
91 						regulator-max-microvolt = <1000000>;
92 						regulator-always-on;
93 						regulator-boot-on;
94 					};
95 
96 					smps45 {
97 						regulator-name = "vd-soc";
98 						regulator-min-microvolt = <1100000>;
99 						regulator-max-microvolt = <1100000>;
100 						regulator-always-on;
101 						regulator-boot-on;
102 					};
103 
104 					smps6 {
105 						regulator-name = "va-lcd-hv";
106 						regulator-min-microvolt = <3000000>;
107 						regulator-max-microvolt = <3000000>;
108 						regulator-always-on;
109 						regulator-boot-on;
110 					};
111 
112 					smps7 {
113 						regulator-name = "vd-ddr";
114 						regulator-min-microvolt = <1350000>;
115 						regulator-max-microvolt = <1350000>;
116 						regulator-always-on;
117 						regulator-boot-on;
118 					};
119 
120 					vdd_1v8: smps8 {
121 						regulator-name = "vs-pmu-1v8";
122 						regulator-min-microvolt = <1800000>;
123 						regulator-max-microvolt = <1800000>;
124 						regulator-always-on;
125 						regulator-boot-on;
126 					};
127 
128 					vdd_2v9_sys: smps9 {
129 						regulator-name = "vs-sys-2v9";
130 						regulator-min-microvolt = <2900000>;
131 						regulator-max-microvolt = <2900000>;
132 						regulator-always-on;
133 						regulator-boot-on;
134 					};
135 
136 					vdd_smps10_out1: smps10_out1 {
137 						regulator-name = "vd-smps10-out1";
138 						regulator-min-microvolt = <5000000>;
139 						regulator-max-microvolt = <5000000>;
140 						regulator-always-on;
141 						regulator-boot-on;
142 					};
143 
144 					vdd_smps10_out2: smps10_out2 {
145 						regulator-name = "vd-smps10-out2";
146 						regulator-min-microvolt = <5000000>;
147 						regulator-max-microvolt = <5000000>;
148 						regulator-always-on;
149 						regulator-boot-on;
150 					};
151 
152 					ldo1 {
153 						regulator-name = "va-pllx";
154 						regulator-min-microvolt = <1050000>;
155 						regulator-max-microvolt = <1050000>;
156 						regulator-always-on;
157 						regulator-boot-on;
158 					};
159 
160 					vdd_1v2_ap: ldo2 {
161 						regulator-name = "va-ap-1v2";
162 						regulator-min-microvolt = <1200000>;
163 						regulator-max-microvolt = <1200000>;
164 						regulator-always-on;
165 						regulator-boot-on;
166 					};
167 
168 					ldo3 {
169 						regulator-name = "vd-fuse";
170 						regulator-min-microvolt = <1800000>;
171 						regulator-max-microvolt = <1800000>;
172 						regulator-always-on;
173 						regulator-boot-on;
174 					};
175 
176 					ldo4 {
177 						regulator-name = "vd-ts-hv";
178 						regulator-min-microvolt = <3200000>;
179 						regulator-max-microvolt = <3200000>;
180 						regulator-always-on;
181 						regulator-boot-on;
182 					};
183 
184 					ldo5 {
185 						regulator-name = "va-cam2-hv";
186 						regulator-min-microvolt = <2700000>;
187 						regulator-max-microvolt = <2700000>;
188 					};
189 
190 					ldo6 {
191 						regulator-name = "va-sns-hv";
192 						regulator-min-microvolt = <2850000>;
193 						regulator-max-microvolt = <2850000>;
194 					};
195 
196 					ldo7 {
197 						regulator-name = "va-cam1-hv";
198 						regulator-min-microvolt = <2700000>;
199 						regulator-max-microvolt = <2700000>;
200 					};
201 
202 					ldo8 {
203 						regulator-name = "va-ap-rtc";
204 						regulator-min-microvolt = <1100000>;
205 						regulator-max-microvolt = <1100000>;
206 						ti,enable-ldo8-tracking;
207 						regulator-always-on;
208 						regulator-boot-on;
209 					};
210 
211 					ldo9 {
212 						regulator-name = "vi-sdcard";
213 						regulator-min-microvolt = <2900000>;
214 						regulator-max-microvolt = <2900000>;
215 					};
216 
217 					ldousb {
218 						regulator-name = "avdd-usb";
219 						regulator-min-microvolt = <3300000>;
220 						regulator-max-microvolt = <3300000>;
221 						regulator-always-on;
222 						regulator-boot-on;
223 					};
224 
225 					ldoln {
226 						regulator-name = "va-hdmi";
227 						regulator-min-microvolt = <3300000>;
228 						regulator-max-microvolt = <3300000>;
229 					};
230 				};
231 			};
232 
233 			rtc {
234 				compatible = "ti,palmas-rtc";
235 				interrupt-parent = <&palmas>;
236 				interrupts = <8 0>;
237 			};
238 
239 		};
240 	};
241 
242 	pmc@7000e400 {
243 		nvidia,invert-interrupt;
244 	};
245 
246 	/* eMMC */
247 	mmc@78000600 {
248 		status = "okay";
249 		bus-width = <8>;
250 		non-removable;
251 	};
252 
253 	usb@7d000000 {
254 		status = "okay";
255 	};
256 
257 	usb-phy@7d000000 {
258 		status = "okay";
259 		nvidia,xcvr-setup = <7>;
260 		nvidia,xcvr-lsfslew = <2>;
261 		nvidia,xcvr-lsrslew = <2>;
262 		interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
263 		/* Should be changed to "otg" once we have vbus_supply */
264 		/* As of now, USB devices need to be powered externally */
265 		dr_mode = "host";
266 	};
267 
268 	backlight: backlight {
269 		compatible = "pwm-backlight";
270 		pwms = <&pwm 1 40000>;
271 
272 		brightness-levels = <0 4 8 16 32 64 128 255>;
273 		default-brightness-level = <6>;
274 
275 		power-supply = <&lcd_bl_en>;
276 	};
277 
278 	clk32k_in: clock-32k {
279 		compatible = "fixed-clock";
280 		clock-frequency = <32768>;
281 		#clock-cells = <0>;
282 	};
283 
284 	gpio-keys {
285 		compatible = "gpio-keys";
286 
287 		key-power {
288 			label = "Power";
289 			gpios = <&gpio TEGRA_GPIO(Q, 0) GPIO_ACTIVE_LOW>;
290 			linux,code = <KEY_POWER>;
291 			wakeup-source;
292 		};
293 
294 		key-volume-down {
295 			label = "Volume Down";
296 			gpios = <&gpio TEGRA_GPIO(Q, 2) GPIO_ACTIVE_LOW>;
297 			linux,code = <KEY_VOLUMEDOWN>;
298 		};
299 
300 		key-volume-up {
301 			label = "Volume Up";
302 			gpios = <&gpio TEGRA_GPIO(R, 2) GPIO_ACTIVE_LOW>;
303 			linux,code = <KEY_VOLUMEUP>;
304 		};
305 	};
306 
307 	/* FIXME: output of BQ24192 */
308 	vs_sys: regulator-vs {
309 		compatible = "regulator-fixed";
310 		regulator-name = "VS_SYS";
311 		regulator-min-microvolt = <4200000>;
312 		regulator-max-microvolt = <4200000>;
313 		regulator-always-on;
314 		regulator-boot-on;
315 	};
316 
317 	lcd_bl_en: regulator-lcden {
318 		compatible = "regulator-fixed";
319 		regulator-name = "VDD_LCD_BL";
320 		regulator-min-microvolt = <16500000>;
321 		regulator-max-microvolt = <16500000>;
322 		gpio = <&gpio TEGRA_GPIO(H, 2) GPIO_ACTIVE_HIGH>;
323 		enable-active-high;
324 		vin-supply = <&vs_sys>;
325 		regulator-boot-on;
326 	};
327 
328 	vdd_lcd: regulator-lcd {
329 		compatible = "regulator-fixed";
330 		regulator-name = "VD_LCD_1V8";
331 		regulator-min-microvolt = <1800000>;
332 		regulator-max-microvolt = <1800000>;
333 		gpio = <&palmas_gpio 4 GPIO_ACTIVE_HIGH>;
334 		enable-active-high;
335 		vin-supply = <&vdd_1v8>;
336 		regulator-boot-on;
337 	};
338 };
339