xref: /freebsd-src/sys/contrib/device-tree/src/arm/aspeed/aspeed-bmc-facebook-wedge400.dts (revision 8d13bc63c0e1d50bc9e47ac1f26329c999bfecf0)
1f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0+
2f126890aSEmmanuel Vadot// Copyright (c) 2019 Facebook Inc.
3f126890aSEmmanuel Vadot/dts-v1/;
4f126890aSEmmanuel Vadot
5f126890aSEmmanuel Vadot#include <dt-bindings/gpio/aspeed-gpio.h>
6f126890aSEmmanuel Vadot#include "ast2500-facebook-netbmc-common.dtsi"
7f126890aSEmmanuel Vadot
8f126890aSEmmanuel Vadot/ {
9f126890aSEmmanuel Vadot	model = "Facebook Wedge 400 BMC";
10f126890aSEmmanuel Vadot	compatible = "facebook,wedge400-bmc", "aspeed,ast2500";
11f126890aSEmmanuel Vadot
12f126890aSEmmanuel Vadot	aliases {
13f126890aSEmmanuel Vadot		/*
14f126890aSEmmanuel Vadot		 * PCA9548 (2-0070) provides 8 channels connecting to
15f126890aSEmmanuel Vadot		 * SCM (System Controller Module).
16f126890aSEmmanuel Vadot		 */
17f126890aSEmmanuel Vadot		i2c16 = &imux16;
18f126890aSEmmanuel Vadot		i2c17 = &imux17;
19f126890aSEmmanuel Vadot		i2c18 = &imux18;
20f126890aSEmmanuel Vadot		i2c19 = &imux19;
21f126890aSEmmanuel Vadot		i2c20 = &imux20;
22f126890aSEmmanuel Vadot		i2c21 = &imux21;
23f126890aSEmmanuel Vadot		i2c22 = &imux22;
24f126890aSEmmanuel Vadot		i2c23 = &imux23;
25f126890aSEmmanuel Vadot
26f126890aSEmmanuel Vadot		/*
27f126890aSEmmanuel Vadot		 * PCA9548 (8-0070) provides 8 channels connecting to
28f126890aSEmmanuel Vadot		 * SMB (Switch Main Board).
29f126890aSEmmanuel Vadot		 */
30f126890aSEmmanuel Vadot		i2c24 = &imux24;
31f126890aSEmmanuel Vadot		i2c25 = &imux25;
32f126890aSEmmanuel Vadot		i2c26 = &imux26;
33f126890aSEmmanuel Vadot		i2c27 = &imux27;
34f126890aSEmmanuel Vadot		i2c28 = &imux28;
35f126890aSEmmanuel Vadot		i2c29 = &imux29;
36f126890aSEmmanuel Vadot		i2c30 = &imux30;
37f126890aSEmmanuel Vadot		i2c31 = &imux31;
38f126890aSEmmanuel Vadot
39f126890aSEmmanuel Vadot		/*
40f126890aSEmmanuel Vadot		 * PCA9548 (11-0076) provides 8 channels connecting to
41f126890aSEmmanuel Vadot		 * FCM (Fan Controller Module).
42f126890aSEmmanuel Vadot		 */
43f126890aSEmmanuel Vadot		i2c32 = &imux32;
44f126890aSEmmanuel Vadot		i2c33 = &imux33;
45f126890aSEmmanuel Vadot		i2c34 = &imux34;
46f126890aSEmmanuel Vadot		i2c35 = &imux35;
47f126890aSEmmanuel Vadot		i2c36 = &imux36;
48f126890aSEmmanuel Vadot		i2c37 = &imux37;
49f126890aSEmmanuel Vadot		i2c38 = &imux38;
50f126890aSEmmanuel Vadot		i2c39 = &imux39;
51f126890aSEmmanuel Vadot
52f126890aSEmmanuel Vadot		spi2 = &spi_gpio;
53f126890aSEmmanuel Vadot	};
54f126890aSEmmanuel Vadot
55f126890aSEmmanuel Vadot	chosen {
56f126890aSEmmanuel Vadot		stdout-path = &uart1;
57f126890aSEmmanuel Vadot		bootargs = "console=ttyS0,9600n8 root=/dev/ram rw";
58f126890aSEmmanuel Vadot	};
59f126890aSEmmanuel Vadot
60f126890aSEmmanuel Vadot	ast-adc-hwmon {
61f126890aSEmmanuel Vadot		compatible = "iio-hwmon";
62aa1a8ff2SEmmanuel Vadot		io-channels = <&adc 0>, <&adc 1>, <&adc 2>, <&adc 3>, <&adc 4>,
63aa1a8ff2SEmmanuel Vadot			      <&adc 5>, <&adc 6>, <&adc 7>, <&adc 8>;
64f126890aSEmmanuel Vadot	};
65f126890aSEmmanuel Vadot
66f126890aSEmmanuel Vadot	/*
67f126890aSEmmanuel Vadot	 * GPIO-based SPI Master is required to access SPI TPM, because
68f126890aSEmmanuel Vadot	 * full-duplex SPI transactions are not supported by ASPEED SPI
69f126890aSEmmanuel Vadot	 * Controllers.
70f126890aSEmmanuel Vadot	 */
71f126890aSEmmanuel Vadot	spi_gpio: spi {
72f126890aSEmmanuel Vadot		status = "okay";
73f126890aSEmmanuel Vadot		compatible = "spi-gpio";
74f126890aSEmmanuel Vadot		#address-cells = <1>;
75f126890aSEmmanuel Vadot		#size-cells = <0>;
76f126890aSEmmanuel Vadot
77f126890aSEmmanuel Vadot		cs-gpios = <&gpio ASPEED_GPIO(R, 2) GPIO_ACTIVE_LOW>;
78f126890aSEmmanuel Vadot		gpio-sck = <&gpio ASPEED_GPIO(R, 3) GPIO_ACTIVE_HIGH>;
79f126890aSEmmanuel Vadot		gpio-mosi = <&gpio ASPEED_GPIO(R, 4) GPIO_ACTIVE_HIGH>;
80f126890aSEmmanuel Vadot		gpio-miso = <&gpio ASPEED_GPIO(R, 5) GPIO_ACTIVE_HIGH>;
81f126890aSEmmanuel Vadot		num-chipselects = <1>;
82f126890aSEmmanuel Vadot
83*8d13bc63SEmmanuel Vadot		tpm@0 {
84*8d13bc63SEmmanuel Vadot			compatible = "infineon,slb9670", "tcg,tpm_tis-spi";
85f126890aSEmmanuel Vadot			spi-max-frequency = <33000000>;
86f126890aSEmmanuel Vadot			reg = <0>;
87f126890aSEmmanuel Vadot		};
88f126890aSEmmanuel Vadot	};
89f126890aSEmmanuel Vadot};
90f126890aSEmmanuel Vadot
91f126890aSEmmanuel Vadot/*
92f126890aSEmmanuel Vadot * Both firmware flashes are 128MB on Wedge400 BMC.
93f126890aSEmmanuel Vadot */
94f126890aSEmmanuel Vadot&fmc_flash0 {
95f126890aSEmmanuel Vadot#include "facebook-bmc-flash-layout-128.dtsi"
96f126890aSEmmanuel Vadot};
97f126890aSEmmanuel Vadot
98f126890aSEmmanuel Vadot&fmc_flash1 {
99f126890aSEmmanuel Vadot	partitions {
100f126890aSEmmanuel Vadot		compatible = "fixed-partitions";
101f126890aSEmmanuel Vadot		#address-cells = <1>;
102f126890aSEmmanuel Vadot		#size-cells = <1>;
103f126890aSEmmanuel Vadot
104f126890aSEmmanuel Vadot		flash1@0 {
105f126890aSEmmanuel Vadot			reg = <0x0 0x8000000>;
106f126890aSEmmanuel Vadot			label = "flash1";
107f126890aSEmmanuel Vadot		};
108f126890aSEmmanuel Vadot	};
109f126890aSEmmanuel Vadot};
110f126890aSEmmanuel Vadot
111f126890aSEmmanuel Vadot&uart2 {
112f126890aSEmmanuel Vadot	status = "okay";
113f126890aSEmmanuel Vadot	pinctrl-names = "default";
114f126890aSEmmanuel Vadot	pinctrl-0 = <&pinctrl_txd2_default
115f126890aSEmmanuel Vadot		     &pinctrl_rxd2_default>;
116f126890aSEmmanuel Vadot};
117f126890aSEmmanuel Vadot
118f126890aSEmmanuel Vadot&uart4 {
119f126890aSEmmanuel Vadot	status = "okay";
120f126890aSEmmanuel Vadot	pinctrl-names = "default";
121f126890aSEmmanuel Vadot	pinctrl-0 = <&pinctrl_txd4_default
122f126890aSEmmanuel Vadot		     &pinctrl_rxd4_default>;
123f126890aSEmmanuel Vadot};
124f126890aSEmmanuel Vadot
125f126890aSEmmanuel Vadot/*
126f126890aSEmmanuel Vadot * I2C bus #0 is multi-master environment dedicated for BMC and Bridge IC
127f126890aSEmmanuel Vadot * communication.
128f126890aSEmmanuel Vadot */
129f126890aSEmmanuel Vadot&i2c0 {
130f126890aSEmmanuel Vadot	status = "okay";
131f126890aSEmmanuel Vadot	multi-master;
132f126890aSEmmanuel Vadot	bus-frequency = <1000000>;
133f126890aSEmmanuel Vadot};
134f126890aSEmmanuel Vadot
135f126890aSEmmanuel Vadot&i2c1 {
136f126890aSEmmanuel Vadot	status = "okay";
137f126890aSEmmanuel Vadot};
138f126890aSEmmanuel Vadot
139f126890aSEmmanuel Vadot&i2c2 {
140f126890aSEmmanuel Vadot	status = "okay";
141f126890aSEmmanuel Vadot
142aa1a8ff2SEmmanuel Vadot	i2c-mux@70 {
143f126890aSEmmanuel Vadot		compatible = "nxp,pca9548";
144f126890aSEmmanuel Vadot		#address-cells = <1>;
145f126890aSEmmanuel Vadot		#size-cells = <0>;
146f126890aSEmmanuel Vadot		reg = <0x70>;
147f126890aSEmmanuel Vadot		i2c-mux-idle-disconnect;
148f126890aSEmmanuel Vadot
149f126890aSEmmanuel Vadot		imux16: i2c@0 {
150f126890aSEmmanuel Vadot			#address-cells = <1>;
151f126890aSEmmanuel Vadot			#size-cells = <0>;
152f126890aSEmmanuel Vadot			reg = <0>;
153f126890aSEmmanuel Vadot		};
154f126890aSEmmanuel Vadot
155f126890aSEmmanuel Vadot		imux17: i2c@1 {
156f126890aSEmmanuel Vadot			#address-cells = <1>;
157f126890aSEmmanuel Vadot			#size-cells = <0>;
158f126890aSEmmanuel Vadot			reg = <1>;
159f126890aSEmmanuel Vadot		};
160f126890aSEmmanuel Vadot
161f126890aSEmmanuel Vadot		imux18: i2c@2 {
162f126890aSEmmanuel Vadot			#address-cells = <1>;
163f126890aSEmmanuel Vadot			#size-cells = <0>;
164f126890aSEmmanuel Vadot			reg = <2>;
165f126890aSEmmanuel Vadot		};
166f126890aSEmmanuel Vadot
167f126890aSEmmanuel Vadot		imux19: i2c@3 {
168f126890aSEmmanuel Vadot			#address-cells = <1>;
169f126890aSEmmanuel Vadot			#size-cells = <0>;
170f126890aSEmmanuel Vadot			reg = <3>;
171f126890aSEmmanuel Vadot		};
172f126890aSEmmanuel Vadot
173f126890aSEmmanuel Vadot		imux20: i2c@4 {
174f126890aSEmmanuel Vadot			#address-cells = <1>;
175f126890aSEmmanuel Vadot			#size-cells = <0>;
176f126890aSEmmanuel Vadot			reg = <4>;
177f126890aSEmmanuel Vadot		};
178f126890aSEmmanuel Vadot
179f126890aSEmmanuel Vadot		imux21: i2c@5 {
180f126890aSEmmanuel Vadot			#address-cells = <1>;
181f126890aSEmmanuel Vadot			#size-cells = <0>;
182f126890aSEmmanuel Vadot			reg = <5>;
183f126890aSEmmanuel Vadot		};
184f126890aSEmmanuel Vadot
185f126890aSEmmanuel Vadot		imux22: i2c@6 {
186f126890aSEmmanuel Vadot			#address-cells = <1>;
187f126890aSEmmanuel Vadot			#size-cells = <0>;
188f126890aSEmmanuel Vadot			reg = <6>;
189f126890aSEmmanuel Vadot		};
190f126890aSEmmanuel Vadot
191f126890aSEmmanuel Vadot		imux23: i2c@7 {
192f126890aSEmmanuel Vadot			#address-cells = <1>;
193f126890aSEmmanuel Vadot			#size-cells = <0>;
194f126890aSEmmanuel Vadot			reg = <7>;
195f126890aSEmmanuel Vadot		};
196f126890aSEmmanuel Vadot	};
197f126890aSEmmanuel Vadot};
198f126890aSEmmanuel Vadot
199f126890aSEmmanuel Vadot&i2c3 {
200f126890aSEmmanuel Vadot	status = "okay";
201f126890aSEmmanuel Vadot};
202f126890aSEmmanuel Vadot
203f126890aSEmmanuel Vadot&i2c4 {
204f126890aSEmmanuel Vadot	status = "okay";
205f126890aSEmmanuel Vadot};
206f126890aSEmmanuel Vadot
207f126890aSEmmanuel Vadot&i2c5 {
208f126890aSEmmanuel Vadot	status = "okay";
209f126890aSEmmanuel Vadot};
210f126890aSEmmanuel Vadot
211f126890aSEmmanuel Vadot&i2c6 {
212f126890aSEmmanuel Vadot	status = "okay";
213f126890aSEmmanuel Vadot};
214f126890aSEmmanuel Vadot
215f126890aSEmmanuel Vadot&i2c7 {
216f126890aSEmmanuel Vadot	status = "okay";
217f126890aSEmmanuel Vadot};
218f126890aSEmmanuel Vadot
219f126890aSEmmanuel Vadot&i2c8 {
220f126890aSEmmanuel Vadot	status = "okay";
221f126890aSEmmanuel Vadot
222aa1a8ff2SEmmanuel Vadot	i2c-mux@70 {
223f126890aSEmmanuel Vadot		compatible = "nxp,pca9548";
224f126890aSEmmanuel Vadot		#address-cells = <1>;
225f126890aSEmmanuel Vadot		#size-cells = <0>;
226f126890aSEmmanuel Vadot		reg = <0x70>;
227f126890aSEmmanuel Vadot		i2c-mux-idle-disconnect;
228f126890aSEmmanuel Vadot
229f126890aSEmmanuel Vadot		imux24: i2c@0 {
230f126890aSEmmanuel Vadot			#address-cells = <1>;
231f126890aSEmmanuel Vadot			#size-cells = <0>;
232f126890aSEmmanuel Vadot			reg = <0>;
233f126890aSEmmanuel Vadot		};
234f126890aSEmmanuel Vadot
235f126890aSEmmanuel Vadot		imux25: i2c@1 {
236f126890aSEmmanuel Vadot			#address-cells = <1>;
237f126890aSEmmanuel Vadot			#size-cells = <0>;
238f126890aSEmmanuel Vadot			reg = <1>;
239f126890aSEmmanuel Vadot		};
240f126890aSEmmanuel Vadot
241f126890aSEmmanuel Vadot		imux26: i2c@2 {
242f126890aSEmmanuel Vadot			#address-cells = <1>;
243f126890aSEmmanuel Vadot			#size-cells = <0>;
244f126890aSEmmanuel Vadot			reg = <2>;
245f126890aSEmmanuel Vadot		};
246f126890aSEmmanuel Vadot
247f126890aSEmmanuel Vadot		imux27: i2c@3 {
248f126890aSEmmanuel Vadot			#address-cells = <1>;
249f126890aSEmmanuel Vadot			#size-cells = <0>;
250f126890aSEmmanuel Vadot			reg = <3>;
251f126890aSEmmanuel Vadot		};
252f126890aSEmmanuel Vadot
253f126890aSEmmanuel Vadot		imux28: i2c@4 {
254f126890aSEmmanuel Vadot			#address-cells = <1>;
255f126890aSEmmanuel Vadot			#size-cells = <0>;
256f126890aSEmmanuel Vadot			reg = <4>;
257f126890aSEmmanuel Vadot		};
258f126890aSEmmanuel Vadot
259f126890aSEmmanuel Vadot		imux29: i2c@5 {
260f126890aSEmmanuel Vadot			#address-cells = <1>;
261f126890aSEmmanuel Vadot			#size-cells = <0>;
262f126890aSEmmanuel Vadot			reg = <5>;
263f126890aSEmmanuel Vadot		};
264f126890aSEmmanuel Vadot
265f126890aSEmmanuel Vadot		imux30: i2c@6 {
266f126890aSEmmanuel Vadot			#address-cells = <1>;
267f126890aSEmmanuel Vadot			#size-cells = <0>;
268f126890aSEmmanuel Vadot			reg = <6>;
269f126890aSEmmanuel Vadot		};
270f126890aSEmmanuel Vadot
271f126890aSEmmanuel Vadot		imux31: i2c@7 {
272f126890aSEmmanuel Vadot			#address-cells = <1>;
273f126890aSEmmanuel Vadot			#size-cells = <0>;
274f126890aSEmmanuel Vadot			reg = <7>;
275f126890aSEmmanuel Vadot		};
276f126890aSEmmanuel Vadot
277f126890aSEmmanuel Vadot	};
278f126890aSEmmanuel Vadot};
279f126890aSEmmanuel Vadot
280f126890aSEmmanuel Vadot&i2c9 {
281f126890aSEmmanuel Vadot	status = "okay";
282f126890aSEmmanuel Vadot};
283f126890aSEmmanuel Vadot
284f126890aSEmmanuel Vadot&i2c10 {
285f126890aSEmmanuel Vadot	status = "okay";
286f126890aSEmmanuel Vadot};
287f126890aSEmmanuel Vadot
288f126890aSEmmanuel Vadot&i2c11 {
289f126890aSEmmanuel Vadot	status = "okay";
290f126890aSEmmanuel Vadot
291aa1a8ff2SEmmanuel Vadot	i2c-mux@76 {
292f126890aSEmmanuel Vadot		compatible = "nxp,pca9548";
293f126890aSEmmanuel Vadot		#address-cells = <1>;
294f126890aSEmmanuel Vadot		#size-cells = <0>;
295f126890aSEmmanuel Vadot		reg = <0x76>;
296f126890aSEmmanuel Vadot		i2c-mux-idle-disconnect;
297f126890aSEmmanuel Vadot
298f126890aSEmmanuel Vadot		imux32: i2c@0 {
299f126890aSEmmanuel Vadot			#address-cells = <1>;
300f126890aSEmmanuel Vadot			#size-cells = <0>;
301f126890aSEmmanuel Vadot			reg = <0>;
302f126890aSEmmanuel Vadot		};
303f126890aSEmmanuel Vadot
304f126890aSEmmanuel Vadot		imux33: i2c@1 {
305f126890aSEmmanuel Vadot			#address-cells = <1>;
306f126890aSEmmanuel Vadot			#size-cells = <0>;
307f126890aSEmmanuel Vadot			reg = <1>;
308f126890aSEmmanuel Vadot		};
309f126890aSEmmanuel Vadot
310f126890aSEmmanuel Vadot		imux34: i2c@2 {
311f126890aSEmmanuel Vadot			#address-cells = <1>;
312f126890aSEmmanuel Vadot			#size-cells = <0>;
313f126890aSEmmanuel Vadot			reg = <2>;
314f126890aSEmmanuel Vadot		};
315f126890aSEmmanuel Vadot
316f126890aSEmmanuel Vadot		imux35: i2c@3 {
317f126890aSEmmanuel Vadot			#address-cells = <1>;
318f126890aSEmmanuel Vadot			#size-cells = <0>;
319f126890aSEmmanuel Vadot			reg = <3>;
320f126890aSEmmanuel Vadot		};
321f126890aSEmmanuel Vadot
322f126890aSEmmanuel Vadot		imux36: i2c@4 {
323f126890aSEmmanuel Vadot			#address-cells = <1>;
324f126890aSEmmanuel Vadot			#size-cells = <0>;
325f126890aSEmmanuel Vadot			reg = <4>;
326f126890aSEmmanuel Vadot		};
327f126890aSEmmanuel Vadot
328f126890aSEmmanuel Vadot		imux37: i2c@5 {
329f126890aSEmmanuel Vadot			#address-cells = <1>;
330f126890aSEmmanuel Vadot			#size-cells = <0>;
331f126890aSEmmanuel Vadot			reg = <5>;
332f126890aSEmmanuel Vadot		};
333f126890aSEmmanuel Vadot
334f126890aSEmmanuel Vadot		imux38: i2c@6 {
335f126890aSEmmanuel Vadot			#address-cells = <1>;
336f126890aSEmmanuel Vadot			#size-cells = <0>;
337f126890aSEmmanuel Vadot			reg = <6>;
338f126890aSEmmanuel Vadot		};
339f126890aSEmmanuel Vadot
340f126890aSEmmanuel Vadot		imux39: i2c@7 {
341f126890aSEmmanuel Vadot			#address-cells = <1>;
342f126890aSEmmanuel Vadot			#size-cells = <0>;
343f126890aSEmmanuel Vadot			reg = <7>;
344f126890aSEmmanuel Vadot		};
345f126890aSEmmanuel Vadot
346f126890aSEmmanuel Vadot	};
347f126890aSEmmanuel Vadot};
348f126890aSEmmanuel Vadot
349f126890aSEmmanuel Vadot&i2c12 {
350f126890aSEmmanuel Vadot	status = "okay";
351f126890aSEmmanuel Vadot};
352f126890aSEmmanuel Vadot
353f126890aSEmmanuel Vadot&i2c13 {
354f126890aSEmmanuel Vadot	status = "okay";
355f126890aSEmmanuel Vadot};
356f126890aSEmmanuel Vadot
357f126890aSEmmanuel Vadot&adc {
358f126890aSEmmanuel Vadot	status = "okay";
359f126890aSEmmanuel Vadot};
360f126890aSEmmanuel Vadot
361f126890aSEmmanuel Vadot&ehci1 {
362f126890aSEmmanuel Vadot	status = "okay";
363f126890aSEmmanuel Vadot};
364f126890aSEmmanuel Vadot
365f126890aSEmmanuel Vadot&uhci {
366f126890aSEmmanuel Vadot	status = "okay";
367f126890aSEmmanuel Vadot};
368f126890aSEmmanuel Vadot
369f126890aSEmmanuel Vadot&sdhci1 {
370aa1a8ff2SEmmanuel Vadot	max-frequency = <25000000>;
371f126890aSEmmanuel Vadot	/*
372f126890aSEmmanuel Vadot	 * DMA mode needs to be disabled to avoid conflicts with UHCI
373f126890aSEmmanuel Vadot	 * Controller in AST2500 SoC.
374f126890aSEmmanuel Vadot	 */
375f126890aSEmmanuel Vadot	sdhci-caps-mask = <0x0 0x580000>;
376f126890aSEmmanuel Vadot};
377