xref: /freebsd/sys/contrib/device-tree/src/powerpc/mpc5125twr.dts (revision aa1a8ff2d6dbc51ef058f46f3db5a8bb77967145)
1*c66ec88fSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0-or-later
2*c66ec88fSEmmanuel Vadot/*
3*c66ec88fSEmmanuel Vadot * STx/Freescale ADS5125 MPC5125 silicon
4*c66ec88fSEmmanuel Vadot *
5*c66ec88fSEmmanuel Vadot * Copyright (C) 2009 Freescale Semiconductor Inc. All rights reserved.
6*c66ec88fSEmmanuel Vadot *
7*c66ec88fSEmmanuel Vadot * Reworked by Matteo Facchinetti (engineering@sirius-es.it)
8*c66ec88fSEmmanuel Vadot * Copyright (C) 2013 Sirius Electronic Systems
9*c66ec88fSEmmanuel Vadot */
10*c66ec88fSEmmanuel Vadot
11*c66ec88fSEmmanuel Vadot#include <dt-bindings/clock/mpc512x-clock.h>
12*c66ec88fSEmmanuel Vadot
13*c66ec88fSEmmanuel Vadot/dts-v1/;
14*c66ec88fSEmmanuel Vadot
15*c66ec88fSEmmanuel Vadot/ {
16*c66ec88fSEmmanuel Vadot	model = "mpc5125twr"; // In BSP "mpc5125ads"
17*c66ec88fSEmmanuel Vadot	compatible = "fsl,mpc5125ads", "fsl,mpc5125";
18*c66ec88fSEmmanuel Vadot	#address-cells = <1>;
19*c66ec88fSEmmanuel Vadot	#size-cells = <1>;
20*c66ec88fSEmmanuel Vadot	interrupt-parent = <&ipic>;
21*c66ec88fSEmmanuel Vadot
22*c66ec88fSEmmanuel Vadot	aliases {
23*c66ec88fSEmmanuel Vadot		gpio0 = &gpio0;
24*c66ec88fSEmmanuel Vadot		gpio1 = &gpio1;
25*c66ec88fSEmmanuel Vadot		ethernet0 = &eth0;
26*c66ec88fSEmmanuel Vadot	};
27*c66ec88fSEmmanuel Vadot
28*c66ec88fSEmmanuel Vadot	cpus {
29*c66ec88fSEmmanuel Vadot		#address-cells = <1>;
30*c66ec88fSEmmanuel Vadot		#size-cells = <0>;
31*c66ec88fSEmmanuel Vadot
32*c66ec88fSEmmanuel Vadot		PowerPC,5125@0 {
33*c66ec88fSEmmanuel Vadot			device_type = "cpu";
34*c66ec88fSEmmanuel Vadot			reg = <0>;
35*c66ec88fSEmmanuel Vadot			d-cache-line-size = <0x20>;	// 32 bytes
36*c66ec88fSEmmanuel Vadot			i-cache-line-size = <0x20>;	// 32 bytes
37*c66ec88fSEmmanuel Vadot			d-cache-size = <0x8000>;	// L1, 32K
38*c66ec88fSEmmanuel Vadot			i-cache-size = <0x8000>;	// L1, 32K
39*c66ec88fSEmmanuel Vadot			timebase-frequency = <49500000>;// 49.5 MHz (csb/4)
40*c66ec88fSEmmanuel Vadot			bus-frequency = <198000000>;	// 198 MHz csb bus
41*c66ec88fSEmmanuel Vadot			clock-frequency = <396000000>;	// 396 MHz ppc core
42*c66ec88fSEmmanuel Vadot		};
43*c66ec88fSEmmanuel Vadot	};
44*c66ec88fSEmmanuel Vadot
45*c66ec88fSEmmanuel Vadot	memory {
46*c66ec88fSEmmanuel Vadot		device_type = "memory";
47*c66ec88fSEmmanuel Vadot		reg = <0x00000000 0x10000000>;	// 256MB at 0
48*c66ec88fSEmmanuel Vadot	};
49*c66ec88fSEmmanuel Vadot
50*c66ec88fSEmmanuel Vadot	sram@30000000 {
51*c66ec88fSEmmanuel Vadot		compatible = "fsl,mpc5121-sram";
52*c66ec88fSEmmanuel Vadot		reg = <0x30000000 0x08000>;		// 32K at 0x30000000
53*c66ec88fSEmmanuel Vadot	};
54*c66ec88fSEmmanuel Vadot
55*c66ec88fSEmmanuel Vadot	clocks {
56*c66ec88fSEmmanuel Vadot		#address-cells = <1>;
57*c66ec88fSEmmanuel Vadot		#size-cells = <0>;
58*c66ec88fSEmmanuel Vadot
59*c66ec88fSEmmanuel Vadot		osc: osc {
60*c66ec88fSEmmanuel Vadot			compatible = "fixed-clock";
61*c66ec88fSEmmanuel Vadot			#clock-cells = <0>;
62*c66ec88fSEmmanuel Vadot			clock-frequency = <33000000>;
63*c66ec88fSEmmanuel Vadot		};
64*c66ec88fSEmmanuel Vadot	};
65*c66ec88fSEmmanuel Vadot
66*c66ec88fSEmmanuel Vadot	soc@80000000 {
67*c66ec88fSEmmanuel Vadot		compatible = "fsl,mpc5121-immr";
68*c66ec88fSEmmanuel Vadot		#address-cells = <1>;
69*c66ec88fSEmmanuel Vadot		#size-cells = <1>;
70*c66ec88fSEmmanuel Vadot		ranges = <0x0 0x80000000 0x400000>;
71*c66ec88fSEmmanuel Vadot		reg = <0x80000000 0x400000>;
72*c66ec88fSEmmanuel Vadot		bus-frequency = <66000000>;	// 66 MHz ips bus
73*c66ec88fSEmmanuel Vadot
74*c66ec88fSEmmanuel Vadot		// IPIC
75*c66ec88fSEmmanuel Vadot		// interrupts cell = <intr #, sense>
76*c66ec88fSEmmanuel Vadot		// sense values match linux IORESOURCE_IRQ_* defines:
77*c66ec88fSEmmanuel Vadot		// sense == 8: Level, low assertion
78*c66ec88fSEmmanuel Vadot		// sense == 2: Edge, high-to-low change
79*c66ec88fSEmmanuel Vadot		//
80*c66ec88fSEmmanuel Vadot		ipic: interrupt-controller@c00 {
81*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-ipic", "fsl,ipic";
82*c66ec88fSEmmanuel Vadot			interrupt-controller;
83*c66ec88fSEmmanuel Vadot			#address-cells = <0>;
84*c66ec88fSEmmanuel Vadot			#interrupt-cells = <2>;
85*c66ec88fSEmmanuel Vadot			reg = <0xc00 0x100>;
86*c66ec88fSEmmanuel Vadot		};
87*c66ec88fSEmmanuel Vadot
88*c66ec88fSEmmanuel Vadot		rtc@a00 {	// Real time clock
89*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-rtc";
90*c66ec88fSEmmanuel Vadot			reg = <0xa00 0x100>;
91*c66ec88fSEmmanuel Vadot			interrupts = <79 0x8 80 0x8>;
92*c66ec88fSEmmanuel Vadot		};
93*c66ec88fSEmmanuel Vadot
94*c66ec88fSEmmanuel Vadot		reset@e00 {	// Reset module
95*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-reset";
96*c66ec88fSEmmanuel Vadot			reg = <0xe00 0x100>;
97*c66ec88fSEmmanuel Vadot		};
98*c66ec88fSEmmanuel Vadot
99*c66ec88fSEmmanuel Vadot		clks: clock@f00 {	// Clock control
100*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-clock";
101*c66ec88fSEmmanuel Vadot			reg = <0xf00 0x100>;
102*c66ec88fSEmmanuel Vadot			#clock-cells = <1>;
103*c66ec88fSEmmanuel Vadot			clocks = <&osc>;
104*c66ec88fSEmmanuel Vadot			clock-names = "osc";
105*c66ec88fSEmmanuel Vadot		};
106*c66ec88fSEmmanuel Vadot
107*c66ec88fSEmmanuel Vadot		pmc@1000 {  // Power Management Controller
108*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-pmc";
109*c66ec88fSEmmanuel Vadot			reg = <0x1000 0x100>;
110*c66ec88fSEmmanuel Vadot			interrupts = <83 0x2>;
111*c66ec88fSEmmanuel Vadot		};
112*c66ec88fSEmmanuel Vadot
113*c66ec88fSEmmanuel Vadot		gpio0: gpio@1100 {
114*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-gpio";
115*c66ec88fSEmmanuel Vadot			reg = <0x1100 0x080>;
116*c66ec88fSEmmanuel Vadot			interrupts = <78 0x8>;
117*c66ec88fSEmmanuel Vadot		};
118*c66ec88fSEmmanuel Vadot
119*c66ec88fSEmmanuel Vadot		gpio1: gpio@1180 {
120*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-gpio";
121*c66ec88fSEmmanuel Vadot			reg = <0x1180 0x080>;
122*c66ec88fSEmmanuel Vadot			interrupts = <86 0x8>;
123*c66ec88fSEmmanuel Vadot		};
124*c66ec88fSEmmanuel Vadot
125*c66ec88fSEmmanuel Vadot		can@1300 { // CAN rev.2
126*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-mscan";
127*c66ec88fSEmmanuel Vadot			interrupts = <12 0x8>;
128*c66ec88fSEmmanuel Vadot			reg = <0x1300 0x80>;
129*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_BDLC>,
130*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_IPS>,
131*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_SYS>,
132*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_REF>,
133*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_MSCAN0_MCLK>;
134*c66ec88fSEmmanuel Vadot			clock-names = "ipg", "ips", "sys", "ref", "mclk";
135*c66ec88fSEmmanuel Vadot		};
136*c66ec88fSEmmanuel Vadot
137*c66ec88fSEmmanuel Vadot		can@1380 {
138*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-mscan";
139*c66ec88fSEmmanuel Vadot			interrupts = <13 0x8>;
140*c66ec88fSEmmanuel Vadot			reg = <0x1380 0x80>;
141*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_BDLC>,
142*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_IPS>,
143*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_SYS>,
144*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_REF>,
145*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_MSCAN1_MCLK>;
146*c66ec88fSEmmanuel Vadot			clock-names = "ipg", "ips", "sys", "ref", "mclk";
147*c66ec88fSEmmanuel Vadot		};
148*c66ec88fSEmmanuel Vadot
149*c66ec88fSEmmanuel Vadot		sdhc@1500 {
150*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-sdhc";
151*c66ec88fSEmmanuel Vadot			interrupts = <8 0x8>;
152*c66ec88fSEmmanuel Vadot			reg = <0x1500 0x100>;
153*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_IPS>,
154*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_SDHC>;
155*c66ec88fSEmmanuel Vadot			clock-names = "ipg", "per";
156*c66ec88fSEmmanuel Vadot		};
157*c66ec88fSEmmanuel Vadot
158*c66ec88fSEmmanuel Vadot		i2c@1700 {
159*c66ec88fSEmmanuel Vadot			#address-cells = <1>;
160*c66ec88fSEmmanuel Vadot			#size-cells = <0>;
161*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-i2c", "fsl-i2c";
162*c66ec88fSEmmanuel Vadot			reg = <0x1700 0x20>;
163*c66ec88fSEmmanuel Vadot			interrupts = <0x9 0x8>;
164*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_I2C>;
165*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
166*c66ec88fSEmmanuel Vadot		};
167*c66ec88fSEmmanuel Vadot
168*c66ec88fSEmmanuel Vadot		i2c@1720 {
169*c66ec88fSEmmanuel Vadot			#address-cells = <1>;
170*c66ec88fSEmmanuel Vadot			#size-cells = <0>;
171*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-i2c", "fsl-i2c";
172*c66ec88fSEmmanuel Vadot			reg = <0x1720 0x20>;
173*c66ec88fSEmmanuel Vadot			interrupts = <0xa 0x8>;
174*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_I2C>;
175*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
176*c66ec88fSEmmanuel Vadot		};
177*c66ec88fSEmmanuel Vadot
178*c66ec88fSEmmanuel Vadot		i2c@1740 {
179*c66ec88fSEmmanuel Vadot			#address-cells = <1>;
180*c66ec88fSEmmanuel Vadot			#size-cells = <0>;
181*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-i2c", "fsl-i2c";
182*c66ec88fSEmmanuel Vadot			reg = <0x1740 0x20>;
183*c66ec88fSEmmanuel Vadot			interrupts = <0xb 0x8>;
184*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_I2C>;
185*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
186*c66ec88fSEmmanuel Vadot		};
187*c66ec88fSEmmanuel Vadot
188*c66ec88fSEmmanuel Vadot		i2ccontrol@1760 {
189*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-i2c-ctrl";
190*c66ec88fSEmmanuel Vadot			reg = <0x1760 0x8>;
191*c66ec88fSEmmanuel Vadot		};
192*c66ec88fSEmmanuel Vadot
193*c66ec88fSEmmanuel Vadot		diu@2100 {
194*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-diu";
195*c66ec88fSEmmanuel Vadot			reg = <0x2100 0x100>;
196*c66ec88fSEmmanuel Vadot			interrupts = <64 0x8>;
197*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_DIU>;
198*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
199*c66ec88fSEmmanuel Vadot		};
200*c66ec88fSEmmanuel Vadot
201*c66ec88fSEmmanuel Vadot		mdio@2800 {
202*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-fec-mdio";
203*c66ec88fSEmmanuel Vadot			reg = <0x2800 0x800>;
204*c66ec88fSEmmanuel Vadot			#address-cells = <1>;
205*c66ec88fSEmmanuel Vadot			#size-cells = <0>;
206*c66ec88fSEmmanuel Vadot			phy0: ethernet-phy@0 {
207*c66ec88fSEmmanuel Vadot				reg = <1>;
208*c66ec88fSEmmanuel Vadot			};
209*c66ec88fSEmmanuel Vadot		};
210*c66ec88fSEmmanuel Vadot
211*c66ec88fSEmmanuel Vadot		eth0: ethernet@2800 {
212*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-fec";
213*c66ec88fSEmmanuel Vadot			reg = <0x2800 0x800>;
214*c66ec88fSEmmanuel Vadot			local-mac-address = [ 00 00 00 00 00 00 ];
215*c66ec88fSEmmanuel Vadot			interrupts = <4 0x8>;
216*c66ec88fSEmmanuel Vadot			phy-handle = < &phy0 >;
217*c66ec88fSEmmanuel Vadot			phy-connection-type = "rmii";
218*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_FEC>;
219*c66ec88fSEmmanuel Vadot			clock-names = "per";
220*c66ec88fSEmmanuel Vadot		};
221*c66ec88fSEmmanuel Vadot
222*c66ec88fSEmmanuel Vadot		// IO control
223*c66ec88fSEmmanuel Vadot		ioctl@a000 {
224*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-ioctl";
225*c66ec88fSEmmanuel Vadot			reg = <0xA000 0x1000>;
226*c66ec88fSEmmanuel Vadot		};
227*c66ec88fSEmmanuel Vadot
228*c66ec88fSEmmanuel Vadot		// disable USB1 port
229*c66ec88fSEmmanuel Vadot		// TODO:
230*c66ec88fSEmmanuel Vadot		// correct pinmux config and fix USB3320 ulpi dependency
231*c66ec88fSEmmanuel Vadot		// before re-enabling it
232*c66ec88fSEmmanuel Vadot		usb@3000 {
233*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-usb2-dr";
234*c66ec88fSEmmanuel Vadot			reg = <0x3000 0x400>;
235*c66ec88fSEmmanuel Vadot			#address-cells = <1>;
236*c66ec88fSEmmanuel Vadot			#size-cells = <0>;
237*c66ec88fSEmmanuel Vadot			interrupts = <43 0x8>;
238*c66ec88fSEmmanuel Vadot			dr_mode = "host";
239*c66ec88fSEmmanuel Vadot			phy_type = "ulpi";
240*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_USB1>;
241*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
242*c66ec88fSEmmanuel Vadot			status = "disabled";
243*c66ec88fSEmmanuel Vadot		};
244*c66ec88fSEmmanuel Vadot
245*c66ec88fSEmmanuel Vadot		sclpc@10100 {
246*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc512x-lpbfifo";
247*c66ec88fSEmmanuel Vadot			reg = <0x10100 0x50>;
248*c66ec88fSEmmanuel Vadot			interrupts = <7 0x8>;
249*c66ec88fSEmmanuel Vadot			dmas = <&dma0 26>;
250*c66ec88fSEmmanuel Vadot			dma-names = "rx-tx";
251*c66ec88fSEmmanuel Vadot		};
252*c66ec88fSEmmanuel Vadot
253*c66ec88fSEmmanuel Vadot		// 5125 PSCs are not 52xx or 5121 PSC compatible
254*c66ec88fSEmmanuel Vadot		// PSC1 uart0 aka ttyPSC0
255*c66ec88fSEmmanuel Vadot		serial@11100 {
256*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-psc-uart", "fsl,mpc5125-psc";
257*c66ec88fSEmmanuel Vadot			reg = <0x11100 0x100>;
258*c66ec88fSEmmanuel Vadot			interrupts = <40 0x8>;
259*c66ec88fSEmmanuel Vadot			fsl,rx-fifo-size = <16>;
260*c66ec88fSEmmanuel Vadot			fsl,tx-fifo-size = <16>;
261*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_PSC1>,
262*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_PSC1_MCLK>;
263*c66ec88fSEmmanuel Vadot			clock-names = "ipg", "mclk";
264*c66ec88fSEmmanuel Vadot		};
265*c66ec88fSEmmanuel Vadot
266*c66ec88fSEmmanuel Vadot		// PSC9 uart1 aka ttyPSC1
267*c66ec88fSEmmanuel Vadot		serial@11900 {
268*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5125-psc-uart", "fsl,mpc5125-psc";
269*c66ec88fSEmmanuel Vadot			reg = <0x11900 0x100>;
270*c66ec88fSEmmanuel Vadot			interrupts = <40 0x8>;
271*c66ec88fSEmmanuel Vadot			fsl,rx-fifo-size = <16>;
272*c66ec88fSEmmanuel Vadot			fsl,tx-fifo-size = <16>;
273*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_PSC9>,
274*c66ec88fSEmmanuel Vadot				 <&clks MPC512x_CLK_PSC9_MCLK>;
275*c66ec88fSEmmanuel Vadot			clock-names = "ipg", "mclk";
276*c66ec88fSEmmanuel Vadot		};
277*c66ec88fSEmmanuel Vadot
278*c66ec88fSEmmanuel Vadot		pscfifo@11f00 {
279*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-psc-fifo";
280*c66ec88fSEmmanuel Vadot			reg = <0x11f00 0x100>;
281*c66ec88fSEmmanuel Vadot			interrupts = <40 0x8>;
282*c66ec88fSEmmanuel Vadot			clocks = <&clks MPC512x_CLK_PSC_FIFO>;
283*c66ec88fSEmmanuel Vadot			clock-names = "ipg";
284*c66ec88fSEmmanuel Vadot		};
285*c66ec88fSEmmanuel Vadot
286*c66ec88fSEmmanuel Vadot		dma0: dma@14000 {
287*c66ec88fSEmmanuel Vadot			compatible = "fsl,mpc5121-dma"; // BSP name: "mpc512x-dma2"
288*c66ec88fSEmmanuel Vadot			reg = <0x14000 0x1800>;
289*c66ec88fSEmmanuel Vadot			interrupts = <65 0x8>;
290*c66ec88fSEmmanuel Vadot			#dma-cells = <1>;
291*c66ec88fSEmmanuel Vadot		};
292*c66ec88fSEmmanuel Vadot	};
293*c66ec88fSEmmanuel Vadot};
294