blob: dbec7c106e0b69da8db904d3ee094c4b33f6cdee [file] [log] [blame]
Aisheng Dong3d91ba62019-01-11 11:37:29 +00001// SPDX-License-Identifier: GPL-2.0+
2/*
3 * Copyright (C) 2016 Freescale Semiconductor, Inc.
Dong Aisheng0dcd27b2021-03-08 11:14:19 +08004 * Copyright 2017-2020 NXP
Aisheng Dong3d91ba62019-01-11 11:37:29 +00005 * Dong Aisheng <aisheng.dong@nxp.com>
6 */
7
8#include <dt-bindings/clock/imx8-clock.h>
Dong Aisheng16c4ea72021-03-08 11:14:24 +08009#include <dt-bindings/clock/imx8-lpcg.h>
Aisheng Dong3d91ba62019-01-11 11:37:29 +000010#include <dt-bindings/firmware/imx/rsrc.h>
11#include <dt-bindings/gpio/gpio.h>
Anson Huang49dad0c2019-10-07 09:41:47 +080012#include <dt-bindings/input/input.h>
Aisheng Dong3d91ba62019-01-11 11:37:29 +000013#include <dt-bindings/interrupt-controller/arm-gic.h>
14#include <dt-bindings/pinctrl/pads-imx8qxp.h>
Anson Huangf0cac142020-02-22 08:08:52 +080015#include <dt-bindings/thermal/thermal.h>
Aisheng Dong3d91ba62019-01-11 11:37:29 +000016
17/ {
18 interrupt-parent = <&gic>;
19 #address-cells = <2>;
20 #size-cells = <2>;
21
22 aliases {
Peng Fan3c8f8d82020-06-23 14:49:54 +080023 ethernet0 = &fec1;
24 ethernet1 = &fec2;
Anson Huangddabee12019-05-21 08:17:02 +000025 gpio0 = &lsio_gpio0;
26 gpio1 = &lsio_gpio1;
27 gpio2 = &lsio_gpio2;
28 gpio3 = &lsio_gpio3;
29 gpio4 = &lsio_gpio4;
30 gpio5 = &lsio_gpio5;
31 gpio6 = &lsio_gpio6;
32 gpio7 = &lsio_gpio7;
Dong Aisheng35f4e9d2021-03-08 11:14:27 +080033 i2c0 = &i2c0;
34 i2c1 = &i2c1;
35 i2c2 = &i2c2;
36 i2c3 = &i2c3;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000037 mmc0 = &usdhc1;
38 mmc1 = &usdhc2;
39 mmc2 = &usdhc3;
Peng Fan44f45d52020-06-23 14:49:52 +080040 mu0 = &lsio_mu0;
Anson Huang6b2bcbd2019-04-09 05:00:01 +000041 mu1 = &lsio_mu1;
Peng Fan44f45d52020-06-23 14:49:52 +080042 mu2 = &lsio_mu2;
43 mu3 = &lsio_mu3;
44 mu4 = &lsio_mu4;
Dong Aisheng35f4e9d2021-03-08 11:14:27 +080045 serial0 = &lpuart0;
46 serial1 = &lpuart1;
47 serial2 = &lpuart2;
48 serial3 = &lpuart3;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000049 };
50
51 cpus {
52 #address-cells = <2>;
53 #size-cells = <0>;
54
55 /* We have 1 clusters with 4 Cortex-A35 cores */
56 A35_0: cpu@0 {
57 device_type = "cpu";
58 compatible = "arm,cortex-a35";
59 reg = <0x0 0x0>;
60 enable-method = "psci";
Peng Fanebd92292021-11-12 14:26:04 +080061 i-cache-size = <0x8000>;
62 i-cache-line-size = <64>;
63 i-cache-sets = <256>;
64 d-cache-size = <0x8000>;
65 d-cache-line-size = <64>;
66 d-cache-sets = <128>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000067 next-level-cache = <&A35_L2>;
Dong Aisheng26de33a2021-03-08 11:14:23 +080068 clocks = <&clk IMX_SC_R_A35 IMX_SC_PM_CLK_CPU>;
Anson Huang7be494d2019-02-26 05:17:31 +000069 operating-points-v2 = <&a35_opp_table>;
70 #cooling-cells = <2>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000071 };
72
73 A35_1: cpu@1 {
74 device_type = "cpu";
75 compatible = "arm,cortex-a35";
76 reg = <0x0 0x1>;
77 enable-method = "psci";
Peng Fanebd92292021-11-12 14:26:04 +080078 i-cache-size = <0x8000>;
79 i-cache-line-size = <64>;
80 i-cache-sets = <256>;
81 d-cache-size = <0x8000>;
82 d-cache-line-size = <64>;
83 d-cache-sets = <128>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000084 next-level-cache = <&A35_L2>;
Dong Aisheng26de33a2021-03-08 11:14:23 +080085 clocks = <&clk IMX_SC_R_A35 IMX_SC_PM_CLK_CPU>;
Anson Huang7be494d2019-02-26 05:17:31 +000086 operating-points-v2 = <&a35_opp_table>;
87 #cooling-cells = <2>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +000088 };
89
90 A35_2: cpu@2 {
91 device_type = "cpu";
92 compatible = "arm,cortex-a35";
93 reg = <0x0 0x2>;
94 enable-method = "psci";
Peng Fanebd92292021-11-12 14:26:04 +080095 i-cache-size = <0x8000>;
96 i-cache-line-size = <64>;
97 i-cache-sets = <256>;
98 d-cache-size = <0x8000>;
99 d-cache-line-size = <64>;
100 d-cache-sets = <128>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000101 next-level-cache = <&A35_L2>;
Dong Aisheng26de33a2021-03-08 11:14:23 +0800102 clocks = <&clk IMX_SC_R_A35 IMX_SC_PM_CLK_CPU>;
Anson Huang7be494d2019-02-26 05:17:31 +0000103 operating-points-v2 = <&a35_opp_table>;
104 #cooling-cells = <2>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000105 };
106
107 A35_3: cpu@3 {
108 device_type = "cpu";
109 compatible = "arm,cortex-a35";
110 reg = <0x0 0x3>;
111 enable-method = "psci";
Peng Fanebd92292021-11-12 14:26:04 +0800112 i-cache-size = <0x8000>;
113 i-cache-line-size = <64>;
114 i-cache-sets = <256>;
115 d-cache-size = <0x8000>;
116 d-cache-line-size = <64>;
117 d-cache-sets = <128>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000118 next-level-cache = <&A35_L2>;
Dong Aisheng26de33a2021-03-08 11:14:23 +0800119 clocks = <&clk IMX_SC_R_A35 IMX_SC_PM_CLK_CPU>;
Anson Huang7be494d2019-02-26 05:17:31 +0000120 operating-points-v2 = <&a35_opp_table>;
121 #cooling-cells = <2>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000122 };
123
124 A35_L2: l2-cache0 {
125 compatible = "cache";
Peng Fanebd92292021-11-12 14:26:04 +0800126 cache-level = <2>;
127 cache-size = <0x80000>;
128 cache-line-size = <64>;
129 cache-sets = <1024>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000130 };
131 };
132
Anson Huang7be494d2019-02-26 05:17:31 +0000133 a35_opp_table: opp-table {
134 compatible = "operating-points-v2";
135 opp-shared;
136
137 opp-900000000 {
138 opp-hz = /bits/ 64 <900000000>;
139 opp-microvolt = <1000000>;
140 clock-latency-ns = <150000>;
141 };
142
143 opp-1200000000 {
144 opp-hz = /bits/ 64 <1200000000>;
145 opp-microvolt = <1100000>;
146 clock-latency-ns = <150000>;
147 opp-suspend;
148 };
149 };
150
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000151 gic: interrupt-controller@51a00000 {
152 compatible = "arm,gic-v3";
153 reg = <0x0 0x51a00000 0 0x10000>, /* GIC Dist */
154 <0x0 0x51b00000 0 0xc0000>; /* GICR (RD_base + SGI_base) */
155 #interrupt-cells = <3>;
156 interrupt-controller;
157 interrupts = <GIC_PPI 9 IRQ_TYPE_LEVEL_HIGH>;
158 };
159
Daniel Balutacd42fa12019-08-07 19:42:57 +0300160 reserved-memory {
161 #address-cells = <2>;
162 #size-cells = <2>;
163 ranges;
164
165 dsp_reserved: dsp@92400000 {
166 reg = <0 0x92400000 0 0x2000000>;
167 no-map;
168 };
169 };
170
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000171 pmu {
Peng Fan16ce4ce2021-08-07 17:45:36 +0800172 compatible = "arm,cortex-a35-pmu";
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000173 interrupts = <GIC_PPI 7 IRQ_TYPE_LEVEL_HIGH>;
174 };
175
176 psci {
177 compatible = "arm,psci-1.0";
178 method = "smc";
179 };
180
181 scu {
182 compatible = "fsl,imx-scu";
Peng Fan68956812020-04-14 21:24:28 +0800183 mbox-names = "tx0",
184 "rx0",
Anson Huang6b2bcbd2019-04-09 05:00:01 +0000185 "gip3";
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000186 mboxes = <&lsio_mu1 0 0
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000187 &lsio_mu1 1 0
Anson Huang6b2bcbd2019-04-09 05:00:01 +0000188 &lsio_mu1 3 3>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000189
Dong Aishengb1484222021-03-08 11:14:18 +0800190 pd: imx8qx-pd {
191 compatible = "fsl,imx8qxp-scu-pd", "fsl,scu-pd";
192 #power-domain-cells = <1>;
193 };
194
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000195 clk: clock-controller {
196 compatible = "fsl,imx8qxp-clk";
Dong Aisheng26de33a2021-03-08 11:14:23 +0800197 #clock-cells = <2>;
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000198 clocks = <&xtal32k &xtal24m>;
199 clock-names = "xtal_32KHz", "xtal_24Mhz";
200 };
201
202 iomuxc: pinctrl {
203 compatible = "fsl,imx8qxp-iomuxc";
204 };
205
Peng Fanef9ed872019-05-24 14:39:13 +0800206 ocotp: imx8qx-ocotp {
207 compatible = "fsl,imx8qxp-scu-ocotp";
208 #address-cells = <1>;
209 #size-cells = <1>;
210 };
211
Anson Huang49dad0c2019-10-07 09:41:47 +0800212 scu_key: scu-key {
213 compatible = "fsl,imx8qxp-sc-key", "fsl,imx-sc-key";
214 linux,keycodes = <KEY_POWER>;
215 status = "disabled";
216 };
217
Anson Huang6334f872019-01-14 09:48:42 +0800218 rtc: rtc {
219 compatible = "fsl,imx8qxp-sc-rtc";
220 };
Anson Huangdb9693a2019-05-12 10:10:35 +0000221
222 watchdog {
223 compatible = "fsl,imx8qxp-sc-wdt", "fsl,imx-sc-wdt";
224 timeout-sec = <60>;
225 };
Anson Huangf0cac142020-02-22 08:08:52 +0800226
227 tsens: thermal-sensor {
228 compatible = "fsl,imx8qxp-sc-thermal", "fsl,imx-sc-thermal";
229 #thermal-sensor-cells = <1>;
230 };
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000231 };
232
233 timer {
234 compatible = "arm,armv8-timer";
235 interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_LOW>, /* Physical Secure */
236 <GIC_PPI 14 IRQ_TYPE_LEVEL_LOW>, /* Physical Non-Secure */
237 <GIC_PPI 11 IRQ_TYPE_LEVEL_LOW>, /* Virtual */
238 <GIC_PPI 10 IRQ_TYPE_LEVEL_LOW>; /* Hypervisor */
239 };
240
241 xtal32k: clock-xtal32k {
242 compatible = "fixed-clock";
243 #clock-cells = <0>;
244 clock-frequency = <32768>;
245 clock-output-names = "xtal_32KHz";
246 };
247
248 xtal24m: clock-xtal24m {
249 compatible = "fixed-clock";
250 #clock-cells = <0>;
251 clock-frequency = <24000000>;
252 clock-output-names = "xtal_24MHz";
253 };
254
Anson Huangf0cac142020-02-22 08:08:52 +0800255 thermal_zones: thermal-zones {
256 cpu-thermal0 {
257 polling-delay-passive = <250>;
258 polling-delay = <2000>;
259 thermal-sensors = <&tsens IMX_SC_R_SYSTEM>;
260
261 trips {
262 cpu_alert0: trip0 {
263 temperature = <107000>;
264 hysteresis = <2000>;
265 type = "passive";
266 };
267
268 cpu_crit0: trip1 {
269 temperature = <127000>;
270 hysteresis = <2000>;
271 type = "critical";
272 };
273 };
274
275 cooling-maps {
276 map0 {
277 trip = <&cpu_alert0>;
278 cooling-device =
279 <&A35_0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
280 <&A35_1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
281 <&A35_2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
282 <&A35_3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
283 };
284 };
285 };
286 };
Dong Aisheng0dcd27b2021-03-08 11:14:19 +0800287
288 /* sorted in register address */
Mirela Rabulea5bb27912021-06-19 17:36:11 +0300289 #include "imx8-ss-img.dtsi"
Dong Aisheng0dcd27b2021-03-08 11:14:19 +0800290 #include "imx8-ss-adma.dtsi"
291 #include "imx8-ss-conn.dtsi"
292 #include "imx8-ss-ddr.dtsi"
293 #include "imx8-ss-lsio.dtsi"
Aisheng Dong3d91ba62019-01-11 11:37:29 +0000294};
Dong Aisheng0dcd27b2021-03-08 11:14:19 +0800295
Mirela Rabulea5bb27912021-06-19 17:36:11 +0300296#include "imx8qxp-ss-img.dtsi"
Dong Aisheng0dcd27b2021-03-08 11:14:19 +0800297#include "imx8qxp-ss-adma.dtsi"
298#include "imx8qxp-ss-conn.dtsi"
299#include "imx8qxp-ss-lsio.dtsi"