xref: /openbmc/linux/arch/mips/boot/dts/ingenic/jz4740.dtsi (revision 2bcb9c25081d116afa3796133033ea3f2f02ee8b)
1b2441318SGreg Kroah-Hartman// SPDX-License-Identifier: GPL-2.0
2c4a11bf4SPaul Cercueil#include <dt-bindings/clock/ingenic,jz4740-cgu.h>
311479e8eSPaul Cercueil#include <dt-bindings/clock/ingenic,tcu.h>
4ff1930c6SPaul Burton
5ffb1843dSPaul Burton/ {
6ffb1843dSPaul Burton	#address-cells = <1>;
7ffb1843dSPaul Burton	#size-cells = <1>;
8ffb1843dSPaul Burton	compatible = "ingenic,jz4740";
98e8261ebSPaul Burton
10c1f6b45eS周琰杰 (Zhou Yanjie)	cpus {
11c1f6b45eS周琰杰 (Zhou Yanjie)		#address-cells = <1>;
12c1f6b45eS周琰杰 (Zhou Yanjie)		#size-cells = <0>;
13c1f6b45eS周琰杰 (Zhou Yanjie)
14c1f6b45eS周琰杰 (Zhou Yanjie)		cpu0: cpu@0 {
15c1f6b45eS周琰杰 (Zhou Yanjie)			device_type = "cpu";
16c1f6b45eS周琰杰 (Zhou Yanjie)			compatible = "ingenic,xburst-mxu1.0";
17c1f6b45eS周琰杰 (Zhou Yanjie)			reg = <0>;
18c1f6b45eS周琰杰 (Zhou Yanjie)
19c1f6b45eS周琰杰 (Zhou Yanjie)			clocks = <&cgu JZ4740_CLK_CCLK>;
20c1f6b45eS周琰杰 (Zhou Yanjie)			clock-names = "cpu";
21c1f6b45eS周琰杰 (Zhou Yanjie)		};
22c1f6b45eS周琰杰 (Zhou Yanjie)	};
23c1f6b45eS周琰杰 (Zhou Yanjie)
245214cae7SAntony Pavlov	cpuintc: interrupt-controller {
258e8261ebSPaul Burton		#address-cells = <0>;
268e8261ebSPaul Burton		#interrupt-cells = <1>;
278e8261ebSPaul Burton		interrupt-controller;
288e8261ebSPaul Burton		compatible = "mti,cpu-interrupt-controller";
298e8261ebSPaul Burton	};
30adbdce77SPaul Burton
31adbdce77SPaul Burton	intc: interrupt-controller@10001000 {
32adbdce77SPaul Burton		compatible = "ingenic,jz4740-intc";
33adbdce77SPaul Burton		reg = <0x10001000 0x14>;
34adbdce77SPaul Burton
35adbdce77SPaul Burton		interrupt-controller;
36adbdce77SPaul Burton		#interrupt-cells = <1>;
37adbdce77SPaul Burton
38adbdce77SPaul Burton		interrupt-parent = <&cpuintc>;
39adbdce77SPaul Burton		interrupts = <2>;
40adbdce77SPaul Burton	};
41ff1930c6SPaul Burton
42ff1930c6SPaul Burton	ext: ext {
43ff1930c6SPaul Burton		compatible = "fixed-clock";
44ff1930c6SPaul Burton		#clock-cells = <0>;
45ff1930c6SPaul Burton	};
46ff1930c6SPaul Burton
47ff1930c6SPaul Burton	rtc: rtc {
48ff1930c6SPaul Burton		compatible = "fixed-clock";
49ff1930c6SPaul Burton		#clock-cells = <0>;
50ff1930c6SPaul Burton		clock-frequency = <32768>;
51ff1930c6SPaul Burton	};
52ff1930c6SPaul Burton
53ff1930c6SPaul Burton	cgu: jz4740-cgu@10000000 {
54ff1930c6SPaul Burton		compatible = "ingenic,jz4740-cgu";
55ff1930c6SPaul Burton		reg = <0x10000000 0x100>;
56ff1930c6SPaul Burton
57ff1930c6SPaul Burton		clocks = <&ext>, <&rtc>;
58ff1930c6SPaul Burton		clock-names = "ext", "rtc";
59ff1930c6SPaul Burton
60ff1930c6SPaul Burton		#clock-cells = <1>;
61ff1930c6SPaul Burton	};
628838245dSPaul Burton
6336aafdbdSPaul Cercueil	tcu: timer@10002000 {
6436aafdbdSPaul Cercueil		compatible = "ingenic,jz4740-tcu", "simple-mfd";
6536aafdbdSPaul Cercueil		reg = <0x10002000 0x1000>;
6636aafdbdSPaul Cercueil		#address-cells = <1>;
6736aafdbdSPaul Cercueil		#size-cells = <1>;
6836aafdbdSPaul Cercueil		ranges = <0x0 0x10002000 0x1000>;
6936aafdbdSPaul Cercueil
7036aafdbdSPaul Cercueil		#clock-cells = <1>;
7136aafdbdSPaul Cercueil
72cf2e6b8eSPaul Cercueil		clocks = <&cgu JZ4740_CLK_RTC>,
73cf2e6b8eSPaul Cercueil			 <&cgu JZ4740_CLK_EXT>,
74cf2e6b8eSPaul Cercueil			 <&cgu JZ4740_CLK_PCLK>,
75cf2e6b8eSPaul Cercueil			 <&cgu JZ4740_CLK_TCU>;
7636aafdbdSPaul Cercueil		clock-names = "rtc", "ext", "pclk", "tcu";
7736aafdbdSPaul Cercueil
7836aafdbdSPaul Cercueil		interrupt-controller;
7936aafdbdSPaul Cercueil		#interrupt-cells = <1>;
8036aafdbdSPaul Cercueil
8136aafdbdSPaul Cercueil		interrupt-parent = <&intc>;
8236aafdbdSPaul Cercueil		interrupts = <23 22 21>;
8311479e8eSPaul Cercueil
8411479e8eSPaul Cercueil		watchdog: watchdog@0 {
8511479e8eSPaul Cercueil			compatible = "ingenic,jz4740-watchdog";
8611479e8eSPaul Cercueil			reg = <0x0 0xc>;
8711479e8eSPaul Cercueil
8811479e8eSPaul Cercueil			clocks = <&tcu TCU_CLK_WDT>;
8911479e8eSPaul Cercueil			clock-names = "wdt";
9011479e8eSPaul Cercueil		};
91bf40bf5eSPaul Cercueil
92bf40bf5eSPaul Cercueil		pwm: pwm@40 {
93bf40bf5eSPaul Cercueil			compatible = "ingenic,jz4740-pwm";
94bf40bf5eSPaul Cercueil			reg = <0x40 0x80>;
95bf40bf5eSPaul Cercueil
96bf40bf5eSPaul Cercueil			#pwm-cells = <3>;
97bf40bf5eSPaul Cercueil
98bf40bf5eSPaul Cercueil			clocks = <&tcu TCU_CLK_TIMER0>, <&tcu TCU_CLK_TIMER1>,
99bf40bf5eSPaul Cercueil				 <&tcu TCU_CLK_TIMER2>, <&tcu TCU_CLK_TIMER3>,
100bf40bf5eSPaul Cercueil				 <&tcu TCU_CLK_TIMER4>, <&tcu TCU_CLK_TIMER5>,
101bf40bf5eSPaul Cercueil				 <&tcu TCU_CLK_TIMER6>, <&tcu TCU_CLK_TIMER7>;
102bf40bf5eSPaul Cercueil			clock-names = "timer0", "timer1", "timer2", "timer3",
103bf40bf5eSPaul Cercueil				      "timer4", "timer5", "timer6", "timer7";
104bf40bf5eSPaul Cercueil		};
10536aafdbdSPaul Cercueil	};
10636aafdbdSPaul Cercueil
107262d62cbSPaul Cercueil	rtc_dev: rtc@10003000 {
108262d62cbSPaul Cercueil		compatible = "ingenic,jz4740-rtc";
109262d62cbSPaul Cercueil		reg = <0x10003000 0x40>;
110262d62cbSPaul Cercueil
111262d62cbSPaul Cercueil		interrupt-parent = <&intc>;
112262d62cbSPaul Cercueil		interrupts = <15>;
113262d62cbSPaul Cercueil
114262d62cbSPaul Cercueil		clocks = <&cgu JZ4740_CLK_RTC>;
115262d62cbSPaul Cercueil		clock-names = "rtc";
116262d62cbSPaul Cercueil	};
117262d62cbSPaul Cercueil
1183951cbb5SPaul Cercueil	pinctrl: pin-controller@10010000 {
1193951cbb5SPaul Cercueil		compatible = "ingenic,jz4740-pinctrl";
1203951cbb5SPaul Cercueil		reg = <0x10010000 0x400>;
1213951cbb5SPaul Cercueil
1223951cbb5SPaul Cercueil		#address-cells = <1>;
1233951cbb5SPaul Cercueil		#size-cells = <0>;
1243951cbb5SPaul Cercueil
1253951cbb5SPaul Cercueil		gpa: gpio@0 {
1263951cbb5SPaul Cercueil			compatible = "ingenic,jz4740-gpio";
1273951cbb5SPaul Cercueil			reg = <0>;
1283951cbb5SPaul Cercueil
1293951cbb5SPaul Cercueil			gpio-controller;
1303951cbb5SPaul Cercueil			gpio-ranges = <&pinctrl 0 0 32>;
1313951cbb5SPaul Cercueil			#gpio-cells = <2>;
1323951cbb5SPaul Cercueil
1333951cbb5SPaul Cercueil			interrupt-controller;
1343951cbb5SPaul Cercueil			#interrupt-cells = <2>;
1353951cbb5SPaul Cercueil
1363951cbb5SPaul Cercueil			interrupt-parent = <&intc>;
1373951cbb5SPaul Cercueil			interrupts = <28>;
1383951cbb5SPaul Cercueil		};
1393951cbb5SPaul Cercueil
1403951cbb5SPaul Cercueil		gpb: gpio@1 {
1413951cbb5SPaul Cercueil			compatible = "ingenic,jz4740-gpio";
1423951cbb5SPaul Cercueil			reg = <1>;
1433951cbb5SPaul Cercueil
1443951cbb5SPaul Cercueil			gpio-controller;
1453951cbb5SPaul Cercueil			gpio-ranges = <&pinctrl 0 32 32>;
1463951cbb5SPaul Cercueil			#gpio-cells = <2>;
1473951cbb5SPaul Cercueil
1483951cbb5SPaul Cercueil			interrupt-controller;
1493951cbb5SPaul Cercueil			#interrupt-cells = <2>;
1503951cbb5SPaul Cercueil
1513951cbb5SPaul Cercueil			interrupt-parent = <&intc>;
1523951cbb5SPaul Cercueil			interrupts = <27>;
1533951cbb5SPaul Cercueil		};
1543951cbb5SPaul Cercueil
1553951cbb5SPaul Cercueil		gpc: gpio@2 {
1563951cbb5SPaul Cercueil			compatible = "ingenic,jz4740-gpio";
1573951cbb5SPaul Cercueil			reg = <2>;
1583951cbb5SPaul Cercueil
1593951cbb5SPaul Cercueil			gpio-controller;
1603951cbb5SPaul Cercueil			gpio-ranges = <&pinctrl 0 64 32>;
1613951cbb5SPaul Cercueil			#gpio-cells = <2>;
1623951cbb5SPaul Cercueil
1633951cbb5SPaul Cercueil			interrupt-controller;
1643951cbb5SPaul Cercueil			#interrupt-cells = <2>;
1653951cbb5SPaul Cercueil
1663951cbb5SPaul Cercueil			interrupt-parent = <&intc>;
1673951cbb5SPaul Cercueil			interrupts = <26>;
1683951cbb5SPaul Cercueil		};
1693951cbb5SPaul Cercueil
1703951cbb5SPaul Cercueil		gpd: gpio@3 {
1713951cbb5SPaul Cercueil			compatible = "ingenic,jz4740-gpio";
1723951cbb5SPaul Cercueil			reg = <3>;
1733951cbb5SPaul Cercueil
1743951cbb5SPaul Cercueil			gpio-controller;
1753951cbb5SPaul Cercueil			gpio-ranges = <&pinctrl 0 96 32>;
1763951cbb5SPaul Cercueil			#gpio-cells = <2>;
1773951cbb5SPaul Cercueil
1783951cbb5SPaul Cercueil			interrupt-controller;
1793951cbb5SPaul Cercueil			#interrupt-cells = <2>;
1803951cbb5SPaul Cercueil
1813951cbb5SPaul Cercueil			interrupt-parent = <&intc>;
1823951cbb5SPaul Cercueil			interrupts = <25>;
1833951cbb5SPaul Cercueil		};
1843951cbb5SPaul Cercueil	};
1853951cbb5SPaul Cercueil
18636ba3eaeSPaul Cercueil	aic: audio-controller@10020000 {
18736ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-i2s";
18836ba3eaeSPaul Cercueil		reg = <0x10020000 0x38>;
18936ba3eaeSPaul Cercueil
19036ba3eaeSPaul Cercueil		#sound-dai-cells = <0>;
19136ba3eaeSPaul Cercueil
19236ba3eaeSPaul Cercueil		interrupt-parent = <&intc>;
19336ba3eaeSPaul Cercueil		interrupts = <18>;
19436ba3eaeSPaul Cercueil
19536ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_AIC>,
19636ba3eaeSPaul Cercueil			 <&cgu JZ4740_CLK_I2S>,
19736ba3eaeSPaul Cercueil			 <&cgu JZ4740_CLK_EXT>,
19836ba3eaeSPaul Cercueil			 <&cgu JZ4740_CLK_PLL_HALF>;
19936ba3eaeSPaul Cercueil		clock-names = "aic", "i2s", "ext", "pll half";
20036ba3eaeSPaul Cercueil
20136ba3eaeSPaul Cercueil		dmas = <&dmac 25 0xffffffff>, <&dmac 24 0xffffffff>;
20236ba3eaeSPaul Cercueil		dma-names = "rx", "tx";
20336ba3eaeSPaul Cercueil	};
20436ba3eaeSPaul Cercueil
20536ba3eaeSPaul Cercueil	codec: audio-codec@100200a4 {
20636ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-codec";
20736ba3eaeSPaul Cercueil		reg = <0x10020080 0x8>;
20836ba3eaeSPaul Cercueil
20936ba3eaeSPaul Cercueil		#sound-dai-cells = <0>;
21036ba3eaeSPaul Cercueil
21136ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_AIC>;
21236ba3eaeSPaul Cercueil		clock-names = "aic";
21336ba3eaeSPaul Cercueil	};
21436ba3eaeSPaul Cercueil
2155dad549dSPaul Cercueil	mmc: mmc@10021000 {
2165dad549dSPaul Cercueil		compatible = "ingenic,jz4740-mmc";
2175dad549dSPaul Cercueil		reg = <0x10021000 0x1000>;
2185dad549dSPaul Cercueil
2195dad549dSPaul Cercueil		clocks = <&cgu JZ4740_CLK_MMC>;
2205dad549dSPaul Cercueil		clock-names = "mmc";
2215dad549dSPaul Cercueil
2225dad549dSPaul Cercueil		interrupt-parent = <&intc>;
2235dad549dSPaul Cercueil		interrupts = <14>;
2245dad549dSPaul Cercueil
2255dad549dSPaul Cercueil		dmas = <&dmac 27 0xffffffff>, <&dmac 26 0xffffffff>;
2265dad549dSPaul Cercueil		dma-names = "rx", "tx";
2275dad549dSPaul Cercueil
2285dad549dSPaul Cercueil		cap-sd-highspeed;
2295dad549dSPaul Cercueil		cap-mmc-highspeed;
2305dad549dSPaul Cercueil		cap-sdio-irq;
2315dad549dSPaul Cercueil	};
2325dad549dSPaul Cercueil
2338838245dSPaul Burton	uart0: serial@10030000 {
2348838245dSPaul Burton		compatible = "ingenic,jz4740-uart";
2358838245dSPaul Burton		reg = <0x10030000 0x100>;
2368838245dSPaul Burton
2378838245dSPaul Burton		interrupt-parent = <&intc>;
2388838245dSPaul Burton		interrupts = <9>;
2398838245dSPaul Burton
2408838245dSPaul Burton		clocks = <&ext>, <&cgu JZ4740_CLK_UART0>;
2418838245dSPaul Burton		clock-names = "baud", "module";
2428838245dSPaul Burton	};
2438838245dSPaul Burton
2448838245dSPaul Burton	uart1: serial@10031000 {
2458838245dSPaul Burton		compatible = "ingenic,jz4740-uart";
2468838245dSPaul Burton		reg = <0x10031000 0x100>;
2478838245dSPaul Burton
2488838245dSPaul Burton		interrupt-parent = <&intc>;
2498838245dSPaul Burton		interrupts = <8>;
2508838245dSPaul Burton
2518838245dSPaul Burton		clocks = <&ext>, <&cgu JZ4740_CLK_UART1>;
2528838245dSPaul Burton		clock-names = "baud", "module";
2538838245dSPaul Burton	};
2549d1e7875SMaarten ter Huurne
25536ba3eaeSPaul Cercueil	adc: adc@10070000 {
25636ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-adc";
25736ba3eaeSPaul Cercueil		reg = <0x10070000 0x30>;
25836ba3eaeSPaul Cercueil		#io-channel-cells = <1>;
25936ba3eaeSPaul Cercueil
26036ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_ADC>;
26136ba3eaeSPaul Cercueil		clock-names = "adc";
26236ba3eaeSPaul Cercueil
26336ba3eaeSPaul Cercueil		interrupt-parent = <&intc>;
26436ba3eaeSPaul Cercueil		interrupts = <12>;
26536ba3eaeSPaul Cercueil	};
26636ba3eaeSPaul Cercueil
26736ba3eaeSPaul Cercueil	nemc: memory-controller@13010000 {
26836ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-nemc";
26936ba3eaeSPaul Cercueil		reg = <0x13010000 0x54>;
27036ba3eaeSPaul Cercueil		#address-cells = <2>;
27136ba3eaeSPaul Cercueil		#size-cells = <1>;
272cf2e6b8eSPaul Cercueil		ranges = <1 0 0x18000000 0x4000000>,
273cf2e6b8eSPaul Cercueil			 <2 0 0x14000000 0x4000000>,
274cf2e6b8eSPaul Cercueil			 <3 0 0x0c000000 0x4000000>,
275cf2e6b8eSPaul Cercueil			 <4 0 0x08000000 0x4000000>;
27636ba3eaeSPaul Cercueil
27736ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_MCLK>;
27836ba3eaeSPaul Cercueil	};
27936ba3eaeSPaul Cercueil
28036ba3eaeSPaul Cercueil	ecc: ecc-controller@13010100 {
28136ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-ecc";
28236ba3eaeSPaul Cercueil		reg = <0x13010100 0x2C>;
28336ba3eaeSPaul Cercueil
28436ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_MCLK>;
28536ba3eaeSPaul Cercueil	};
28636ba3eaeSPaul Cercueil
287d426c517SPaul Cercueil	dmac: dma-controller@13020000 {
288d426c517SPaul Cercueil		compatible = "ingenic,jz4740-dma";
289cf2e6b8eSPaul Cercueil		reg = <0x13020000 0xbc>, <0x13020300 0x14>;
290d426c517SPaul Cercueil		#dma-cells = <2>;
291d426c517SPaul Cercueil
292d426c517SPaul Cercueil		interrupt-parent = <&intc>;
29370999ec1SPaul Cercueil		interrupts = <20>;
294d426c517SPaul Cercueil
295d426c517SPaul Cercueil		clocks = <&cgu JZ4740_CLK_DMA>;
296d426c517SPaul Cercueil	};
297d426c517SPaul Cercueil
298877f2382SSerge Semin	uhc: usb@13030000 {
2999d1e7875SMaarten ter Huurne		compatible = "ingenic,jz4740-ohci", "generic-ohci";
3009d1e7875SMaarten ter Huurne		reg = <0x13030000 0x1000>;
3019d1e7875SMaarten ter Huurne
3029d1e7875SMaarten ter Huurne		clocks = <&cgu JZ4740_CLK_UHC>;
3039d1e7875SMaarten ter Huurne		assigned-clocks = <&cgu JZ4740_CLK_UHC>;
3049d1e7875SMaarten ter Huurne		assigned-clock-rates = <48000000>;
3059d1e7875SMaarten ter Huurne
3069d1e7875SMaarten ter Huurne		interrupt-parent = <&intc>;
3079d1e7875SMaarten ter Huurne		interrupts = <3>;
3089d1e7875SMaarten ter Huurne
3099d1e7875SMaarten ter Huurne		status = "disabled";
3109d1e7875SMaarten ter Huurne	};
31136ba3eaeSPaul Cercueil
31236ba3eaeSPaul Cercueil	udc: usb@13040000 {
31336ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-musb";
31436ba3eaeSPaul Cercueil		reg = <0x13040000 0x10000>;
31536ba3eaeSPaul Cercueil
31636ba3eaeSPaul Cercueil		interrupt-parent = <&intc>;
31736ba3eaeSPaul Cercueil		interrupts = <24>;
31836ba3eaeSPaul Cercueil		interrupt-names = "mc";
31936ba3eaeSPaul Cercueil
32036ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_UDC>;
32136ba3eaeSPaul Cercueil		clock-names = "udc";
32236ba3eaeSPaul Cercueil	};
32336ba3eaeSPaul Cercueil
32436ba3eaeSPaul Cercueil	lcd: lcd-controller@13050000 {
32536ba3eaeSPaul Cercueil		compatible = "ingenic,jz4740-lcd";
326*2bcb9c25SH. Nikolaus Schaller		reg = <0x13050000 0x60>; /* LCDCMD1+4 */
32736ba3eaeSPaul Cercueil
32836ba3eaeSPaul Cercueil		interrupt-parent = <&intc>;
32936ba3eaeSPaul Cercueil		interrupts = <30>;
33036ba3eaeSPaul Cercueil
33136ba3eaeSPaul Cercueil		clocks = <&cgu JZ4740_CLK_LCD_PCLK>, <&cgu JZ4740_CLK_LCD>;
33236ba3eaeSPaul Cercueil		clock-names = "lcd_pclk", "lcd";
33336ba3eaeSPaul Cercueil	};
334ffb1843dSPaul Burton};
335