summaryrefslogtreecommitdiff
path: root/arch/arm/boot/dts/nxp/mxs/imx28-btt3.dtsi
blob: a6903ef2b09343f225e22f6715be84097688c18b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/*
 * Copyright 2024
 * Lukasz Majewski, DENX Software Engineering, lukma@denx.de
 */
/dts-v1/;
#include "imx28-lwe.dtsi"

/ {
	model = "BTT3";

	compatible = "lwn,imx28-btt3", "fsl,imx28";

	chosen {
	       bootargs = "root=/dev/mmcblk0p2 rootfstype=ext4 ro rootwait console=ttyAMA0,115200 panic=1 quiet";
	};

	memory@40000000 {
		reg = <0x40000000 0x10000000>;
		device_type = "memory";
	};

	panel {
		compatible = "powertip,hx8238a", "panel-dpi";
		power-supply = <&reg_3v3>;
		width-mm = <70>;
		height-mm = <52>;

		panel-timing {
			clock-frequency = <6500000>;
			hactive = <320>;
			vactive = <240>;
			hfront-porch = <20>;
			hback-porch = <38>;
			hsync-len = <30>;
			vfront-porch = <4>;
			vback-porch = <14>;
			vsync-len = <4>;
			hsync-active = <0>;
			vsync-active = <0>;
			de-active = <0>;
			pixelclk-active = <1>;
		};

		port {
			panel_in: endpoint {
				remote-endpoint = <&display_out>;
			};
		};
	};

	poweroff {
		compatible = "gpio-poweroff";
		gpios = <&gpio0 24 GPIO_ACTIVE_HIGH>;
	};

	sound {
		compatible = "simple-audio-card";
		simple-audio-card,name = "BTTC Audio";
		simple-audio-card,widgets = "Speaker", "BTTC Speaker";
		simple-audio-card,routing = "BTTC Speaker", "SPKOUTN", "BTTC Speaker", "SPKOUTP";

		simple-audio-card,dai-link@0 {
			format = "left_j";
			bitclock-master = <&dai0_master>;
			frame-master = <&dai0_master>;
			mclk-fs = <256>;

			dai0_master: cpu {
				sound-dai = <&saif0>;
			};

			codec {
				sound-dai = <&wm89xx>;
				clocks = <&saif0>;
			};
		};
	};

	wifi_pwrseq: sdio-pwrseq {
		compatible = "mmc-pwrseq-simple";
		pinctrl-names = "default";
		pinctrl-0 = <&wifi_en_pin_bttc>;
		reset-gpios = <&gpio0 27 GPIO_ACTIVE_LOW>;
		/* W1-163 needs 60us for WL_EN to be low and */
		/* 150ms after high before downloading FW is possible */
		post-power-on-delay-ms = <200>;
		power-off-delay-us = <100>;
	};
};

&auart0 {
	pinctrl-names = "default";
	pinctrl-0 = <&auart0_2pins_a>;
	status = "okay";
};

&auart3 {
	pinctrl-names = "default";
	pinctrl-0 = <&auart3_pins_a>;
	uart-has-rtscts;
	status = "okay";
};

&i2c0 {
	wm89xx: audio-codec@1a {
		compatible = "wlf,wm8940";
		reg = <0x1a>;
		#sound-dai-cells = <0>;
	};
};

&lcdif {
	pinctrl-names = "default";
	pinctrl-0 = <&lcdif_24bit_pins_a>, <&lcdif_sync_pins_bttc>,
		    <&lcdif_reset_pins_bttc>;
	status = "okay";

	port {
		display_out: endpoint {
			remote-endpoint = <&panel_in>;
		};
	};
};

&mac0 {
	clocks = <&clks 57>, <&clks 57>, <&clks 64>;
	clock-names = "ipg", "ahb", "enet_out";
	phy-handle = <&mac0_phy>;
	phy-mode = "rmii";
	phy-supply = <&reg_3v3>;
	/*
	 * This MAC address is adjusted during production.
	 * Value specified below is used as a fallback during recovery.
	 */
	local-mac-address = [ 00 11 B8 00 BF 8A ];
	status = "okay";

	mdio {
		#address-cells = <1>;
		#size-cells = <0>;

		mac0_phy: ethernet-phy@0 {
			/* LAN8720Ai - PHY ID */
			compatible = "ethernet-phy-id0007.c0f0","ethernet-phy-ieee802.3-c22";
			reg = <0>;
			smsc,disable-energy-detect;
			max-speed = <100>;
			reset-gpios = <&gpio4 12 GPIO_ACTIVE_LOW>;
			reset-assert-us = <1000>;
			reset-deassert-us = <1000>;
		};
	};
};

&pinctrl {
	pinctrl-names = "default";
	pinctrl-0 = <&hog_pins_a>, <&hog_pins_rev>;

	hog_pins_a: hog@0 {
		reg = <0>;
		fsl,pinmux-ids = <
			MX28_PAD_GPMI_RDY2__GPIO_0_22
			MX28_PAD_GPMI_RDY3__GPIO_0_23
			MX28_PAD_GPMI_RDN__GPIO_0_24
			MX28_PAD_LCD_VSYNC__GPIO_1_28
			MX28_PAD_SSP2_SS1__GPIO_2_20
			MX28_PAD_SSP2_SS2__GPIO_2_21
			MX28_PAD_AUART2_CTS__GPIO_3_10
			MX28_PAD_AUART2_RTS__GPIO_3_11
			MX28_PAD_GPMI_WRN__GPIO_0_25
			MX28_PAD_ENET0_RXD2__GPIO_4_9
			MX28_PAD_ENET0_TXD2__GPIO_4_11
		>;
		fsl,drive-strength = <MXS_DRIVE_4mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_DISABLE>;
	};

	hog_pins_rev: hog@1 {
		reg = <1>;
		fsl,pinmux-ids = <
			MX28_PAD_ENET0_RXD3__GPIO_4_10
			MX28_PAD_ENET0_TX_CLK__GPIO_4_5
			MX28_PAD_ENET0_COL__GPIO_4_14
			MX28_PAD_ENET0_CRS__GPIO_4_15
		>;
		fsl,drive-strength = <MXS_DRIVE_4mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_DISABLE>;
	};

	keypad_pins_bttc: keypad-bttc@0 {
		reg = <0>;
		fsl,pinmux-ids = <
			MX28_PAD_GPMI_D00__GPIO_0_0
			MX28_PAD_AUART0_CTS__GPIO_3_2
			MX28_PAD_AUART0_RTS__GPIO_3_3
			MX28_PAD_GPMI_D03__GPIO_0_3
			MX28_PAD_GPMI_D04__GPIO_0_4
			MX28_PAD_GPMI_D05__GPIO_0_5
			MX28_PAD_GPMI_D06__GPIO_0_6
			MX28_PAD_GPMI_D07__GPIO_0_7
			MX28_PAD_GPMI_CE1N__GPIO_0_17
			MX28_PAD_GPMI_CE2N__GPIO_0_18
			MX28_PAD_GPMI_CE3N__GPIO_0_19
			MX28_PAD_GPMI_RDY0__GPIO_0_20
		>;
		fsl,drive-strength = <MXS_DRIVE_4mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_DISABLE>;
	};

	lcdif_sync_pins_bttc: lcdif-bttc@0 {
		reg = <0>;
		fsl,pinmux-ids = <
			MX28_PAD_LCD_DOTCLK__LCD_DOTCLK
			MX28_PAD_LCD_ENABLE__LCD_ENABLE
			MX28_PAD_LCD_HSYNC__LCD_HSYNC
			MX28_PAD_LCD_RD_E__LCD_VSYNC
		>;
		fsl,drive-strength = <MXS_DRIVE_4mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_DISABLE>;
	};

	lcdif_reset_pins_bttc: lcdif-bttc@1 {
		reg = <1>;
		fsl,pinmux-ids = <
			MX28_PAD_LCD_RESET__GPIO_3_30
		>;
		fsl,drive-strength = <MXS_DRIVE_4mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_ENABLE>;
	};

	ssp1_sdio_pins_a: ssp1-sdio@0 {
		reg = <0>;
		fsl,pinmux-ids = <
			MX28_PAD_SSP1_DATA0__SSP1_D0
			MX28_PAD_GPMI_D01__SSP1_D1
			MX28_PAD_GPMI_D02__SSP1_D2
			MX28_PAD_SSP1_DATA3__SSP1_D3
			MX28_PAD_SSP1_CMD__SSP1_CMD
			MX28_PAD_SSP1_SCK__SSP1_SCK
		>;
		fsl,drive-strength = <MXS_DRIVE_8mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_ENABLE>;
	};

	wifi_en_pin_bttc: wifi-en-pin@0 {
		reg = <0>;
		fsl,pinmux-ids = <
			MX28_PAD_GPMI_CLE__GPIO_0_27
		>;
		fsl,drive-strength = <MXS_DRIVE_8mA>;
		fsl,voltage = <MXS_VOLTAGE_HIGH>;
		fsl,pull-up = <MXS_PULL_ENABLE>;
	};
};

&pwm {
	pinctrl-names = "default";
	pinctrl-0 = <&pwm3_pins_a>;
	status = "okay";
};

&reg_usb_5v {
	gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;
};

&saif0 {
	pinctrl-names = "default";
	pinctrl-0 = <&saif0_pins_a>;
	#sound-dai-cells = <0>;
	assigned-clocks = <&clks 53>;
	assigned-clock-rates = <12000000>;
	status = "okay";
};

&saif1 {
	pinctrl-names = "default";
	pinctrl-0 = <&saif1_pins_a>;
	#sound-dai-cells = <0>;
	fsl,saif-master = <&saif0>;
	status = "okay";
};

&ssp1 {
	compatible = "fsl,imx28-mmc";
	pinctrl-names = "default";
	pinctrl-0 = <&ssp1_sdio_pins_a>;
	bus-width = <4>;
	no-1-8-v;       /* force 3.3V VIO */
	non-removable;
	vmmc-supply = <&reg_3v3>;
	mmc-pwrseq = <&wifi_pwrseq>;
	keep-power-in-suspend;
	status = "okay";

	wifi@1 {
		reg = <1>;
		compatible = "brcm,bcm4329-fmac";
	};
};

&ssp2 {
	compatible = "fsl,imx28-spi";
	pinctrl-names = "default";
	pinctrl-0 = <&spi2_pins_a>;
	status = "okay";
};