armada-ap80x.dtsi 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. /*
  3. * Copyright (C) 2019 Marvell Technology Group Ltd.
  4. *
  5. * Device Tree file for Marvell Armada AP80x.
  6. */
  7. #include <dt-bindings/interrupt-controller/arm-gic.h>
  8. #include <dt-bindings/thermal/thermal.h>
  9. /dts-v1/;
  10. / {
  11. #address-cells = <2>;
  12. #size-cells = <2>;
  13. aliases {
  14. serial0 = &uart0;
  15. serial1 = &uart1;
  16. gpio0 = &ap_gpio;
  17. spi0 = &spi0;
  18. };
  19. psci {
  20. compatible = "arm,psci-0.2";
  21. method = "smc";
  22. };
  23. reserved-memory {
  24. #address-cells = <2>;
  25. #size-cells = <2>;
  26. ranges;
  27. /*
  28. * This area matches the mapping done with a
  29. * mainline U-Boot, and should be updated by the
  30. * bootloader.
  31. */
  32. psci-area@4000000 {
  33. reg = <0x0 0x4000000 0x0 0x200000>;
  34. no-map;
  35. };
  36. };
  37. AP_NAME {
  38. #address-cells = <2>;
  39. #size-cells = <2>;
  40. compatible = "simple-bus";
  41. interrupt-parent = <&gic>;
  42. ranges;
  43. config-space@f0000000 {
  44. #address-cells = <1>;
  45. #size-cells = <1>;
  46. compatible = "simple-bus";
  47. ranges = <0x0 0x0 0xf0000000 0x1000000>;
  48. smmu: iommu@5000000 {
  49. compatible = "marvell,ap806-smmu-500", "arm,mmu-500";
  50. reg = <0x100000 0x100000>;
  51. dma-coherent;
  52. #iommu-cells = <1>;
  53. #global-interrupts = <1>;
  54. interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  55. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  56. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  57. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  58. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  59. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  60. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  61. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  62. <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
  63. status = "disabled";
  64. };
  65. gic: interrupt-controller@210000 {
  66. compatible = "arm,gic-400";
  67. #interrupt-cells = <3>;
  68. #address-cells = <1>;
  69. #size-cells = <1>;
  70. ranges;
  71. interrupt-controller;
  72. interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
  73. reg = <0x210000 0x10000>,
  74. <0x220000 0x20000>,
  75. <0x240000 0x20000>,
  76. <0x260000 0x20000>;
  77. gic_v2m0: v2m@280000 {
  78. compatible = "arm,gic-v2m-frame";
  79. msi-controller;
  80. reg = <0x280000 0x1000>;
  81. arm,msi-base-spi = <160>;
  82. arm,msi-num-spis = <32>;
  83. };
  84. gic_v2m1: v2m@290000 {
  85. compatible = "arm,gic-v2m-frame";
  86. msi-controller;
  87. reg = <0x290000 0x1000>;
  88. arm,msi-base-spi = <192>;
  89. arm,msi-num-spis = <32>;
  90. };
  91. gic_v2m2: v2m@2a0000 {
  92. compatible = "arm,gic-v2m-frame";
  93. msi-controller;
  94. reg = <0x2a0000 0x1000>;
  95. arm,msi-base-spi = <224>;
  96. arm,msi-num-spis = <32>;
  97. };
  98. gic_v2m3: v2m@2b0000 {
  99. compatible = "arm,gic-v2m-frame";
  100. msi-controller;
  101. reg = <0x2b0000 0x1000>;
  102. arm,msi-base-spi = <256>;
  103. arm,msi-num-spis = <32>;
  104. };
  105. };
  106. timer {
  107. compatible = "arm,armv8-timer";
  108. interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
  109. <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
  110. <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
  111. <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
  112. };
  113. pmu {
  114. compatible = "arm,cortex-a72-pmu";
  115. interrupt-parent = <&pic>;
  116. interrupts = <17>;
  117. };
  118. odmi: odmi@300000 {
  119. compatible = "marvell,odmi-controller";
  120. interrupt-controller;
  121. msi-controller;
  122. marvell,odmi-frames = <4>;
  123. reg = <0x300000 0x4000>,
  124. <0x304000 0x4000>,
  125. <0x308000 0x4000>,
  126. <0x30C000 0x4000>;
  127. marvell,spi-base = <128>, <136>, <144>, <152>;
  128. };
  129. gicp: gicp@3f0040 {
  130. compatible = "marvell,ap806-gicp";
  131. reg = <0x3f0040 0x10>;
  132. marvell,spi-ranges = <64 64>, <288 64>;
  133. msi-controller;
  134. };
  135. pic: interrupt-controller@3f0100 {
  136. compatible = "marvell,armada-8k-pic";
  137. reg = <0x3f0100 0x10>;
  138. #interrupt-cells = <1>;
  139. interrupt-controller;
  140. interrupts = <GIC_PPI 15 IRQ_TYPE_LEVEL_HIGH>;
  141. };
  142. sei: interrupt-controller@3f0200 {
  143. compatible = "marvell,ap806-sei";
  144. reg = <0x3f0200 0x40>;
  145. interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
  146. #interrupt-cells = <1>;
  147. interrupt-controller;
  148. msi-controller;
  149. };
  150. xor@400000 {
  151. compatible = "marvell,armada-7k-xor", "marvell,xor-v2";
  152. reg = <0x400000 0x1000>,
  153. <0x410000 0x1000>;
  154. msi-parent = <&gic_v2m0>;
  155. clocks = <&ap_clk 3>;
  156. dma-coherent;
  157. };
  158. xor@420000 {
  159. compatible = "marvell,armada-7k-xor", "marvell,xor-v2";
  160. reg = <0x420000 0x1000>,
  161. <0x430000 0x1000>;
  162. msi-parent = <&gic_v2m0>;
  163. clocks = <&ap_clk 3>;
  164. dma-coherent;
  165. };
  166. xor@440000 {
  167. compatible = "marvell,armada-7k-xor", "marvell,xor-v2";
  168. reg = <0x440000 0x1000>,
  169. <0x450000 0x1000>;
  170. msi-parent = <&gic_v2m0>;
  171. clocks = <&ap_clk 3>;
  172. dma-coherent;
  173. };
  174. xor@460000 {
  175. compatible = "marvell,armada-7k-xor", "marvell,xor-v2";
  176. reg = <0x460000 0x1000>,
  177. <0x470000 0x1000>;
  178. msi-parent = <&gic_v2m0>;
  179. clocks = <&ap_clk 3>;
  180. dma-coherent;
  181. };
  182. spi0: spi@510600 {
  183. compatible = "marvell,armada-380-spi";
  184. reg = <0x510600 0x50>;
  185. #address-cells = <1>;
  186. #size-cells = <0>;
  187. interrupts = <GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>;
  188. clocks = <&ap_clk 3>;
  189. status = "disabled";
  190. };
  191. i2c0: i2c@511000 {
  192. compatible = "marvell,mv78230-i2c";
  193. reg = <0x511000 0x20>;
  194. #address-cells = <1>;
  195. #size-cells = <0>;
  196. interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
  197. clocks = <&ap_clk 3>;
  198. status = "disabled";
  199. };
  200. uart0: serial@512000 {
  201. compatible = "snps,dw-apb-uart";
  202. reg = <0x512000 0x100>;
  203. reg-shift = <2>;
  204. interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>;
  205. reg-io-width = <1>;
  206. clocks = <&ap_clk 3>;
  207. status = "disabled";
  208. };
  209. uart1: serial@512100 {
  210. compatible = "snps,dw-apb-uart";
  211. reg = <0x512100 0x100>;
  212. reg-shift = <2>;
  213. interrupts = <GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>;
  214. reg-io-width = <1>;
  215. clocks = <&ap_clk 3>;
  216. status = "disabled";
  217. };
  218. watchdog: watchdog@610000 {
  219. compatible = "arm,sbsa-gwdt";
  220. reg = <0x610000 0x1000>, <0x600000 0x1000>;
  221. interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
  222. };
  223. ap_sdhci0: mmc@6e0000 {
  224. compatible = "marvell,armada-ap806-sdhci";
  225. reg = <0x6e0000 0x300>;
  226. interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
  227. clock-names = "core";
  228. clocks = <&ap_clk 4>;
  229. dma-coherent;
  230. marvell,xenon-phy-slow-mode;
  231. status = "disabled";
  232. };
  233. ap_syscon0: system-controller@6f4000 {
  234. compatible = "syscon", "simple-mfd";
  235. reg = <0x6f4000 0x2000>;
  236. ap_pinctrl: pinctrl {
  237. compatible = "marvell,ap806-pinctrl";
  238. uart0_pins: uart0-pins {
  239. marvell,pins = "mpp11", "mpp19";
  240. marvell,function = "uart0";
  241. };
  242. };
  243. ap_gpio: gpio@1040 {
  244. compatible = "marvell,armada-8k-gpio";
  245. offset = <0x1040>;
  246. ngpios = <20>;
  247. gpio-controller;
  248. #gpio-cells = <2>;
  249. gpio-ranges = <&ap_pinctrl 0 0 20>;
  250. marvell,pwm-offset = <0x10c0>;
  251. #pwm-cells = <2>;
  252. clocks = <&ap_clk 3>;
  253. };
  254. };
  255. ap_syscon1: system-controller@6f8000 {
  256. compatible = "syscon", "simple-mfd";
  257. reg = <0x6f8000 0x1000>;
  258. #address-cells = <1>;
  259. #size-cells = <1>;
  260. ap_thermal: thermal-sensor@80 {
  261. compatible = "marvell,armada-ap806-thermal";
  262. reg = <0x80 0x10>;
  263. interrupt-parent = <&sei>;
  264. interrupts = <18>;
  265. #thermal-sensor-cells = <1>;
  266. };
  267. };
  268. };
  269. };
  270. /*
  271. * The thermal IP features one internal sensor plus, if applicable, one
  272. * remote channel wired to one sensor per CPU.
  273. *
  274. * Only one thermal zone per AP/CP may trigger interrupts at a time, the
  275. * first one that will have a critical trip point will be chosen.
  276. */
  277. thermal-zones {
  278. ap_thermal_ic: ap-thermal-ic {
  279. polling-delay-passive = <0>; /* Interrupt driven */
  280. polling-delay = <0>; /* Interrupt driven */
  281. thermal-sensors = <&ap_thermal 0>;
  282. trips {
  283. ap_crit: ap-crit {
  284. temperature = <100000>; /* mC degrees */
  285. hysteresis = <2000>; /* mC degrees */
  286. type = "critical";
  287. };
  288. };
  289. cooling-maps { };
  290. };
  291. ap_thermal_cpu0: ap-thermal-cpu0 {
  292. polling-delay-passive = <1000>;
  293. polling-delay = <1000>;
  294. thermal-sensors = <&ap_thermal 1>;
  295. trips {
  296. cpu0_hot: cpu0-hot {
  297. temperature = <85000>;
  298. hysteresis = <2000>;
  299. type = "passive";
  300. };
  301. cpu0_emerg: cpu0-emerg {
  302. temperature = <95000>;
  303. hysteresis = <2000>;
  304. type = "passive";
  305. };
  306. };
  307. cooling-maps {
  308. map0_hot: map0-hot {
  309. trip = <&cpu0_hot>;
  310. cooling-device = <&cpu0 1 2>,
  311. <&cpu1 1 2>;
  312. };
  313. map0_emerg: map0-ermerg {
  314. trip = <&cpu0_emerg>;
  315. cooling-device = <&cpu0 3 3>,
  316. <&cpu1 3 3>;
  317. };
  318. };
  319. };
  320. ap_thermal_cpu1: ap-thermal-cpu1 {
  321. polling-delay-passive = <1000>;
  322. polling-delay = <1000>;
  323. thermal-sensors = <&ap_thermal 2>;
  324. trips {
  325. cpu1_hot: cpu1-hot {
  326. temperature = <85000>;
  327. hysteresis = <2000>;
  328. type = "passive";
  329. };
  330. cpu1_emerg: cpu1-emerg {
  331. temperature = <95000>;
  332. hysteresis = <2000>;
  333. type = "passive";
  334. };
  335. };
  336. cooling-maps {
  337. map1_hot: map1-hot {
  338. trip = <&cpu1_hot>;
  339. cooling-device = <&cpu0 1 2>,
  340. <&cpu1 1 2>;
  341. };
  342. map1_emerg: map1-emerg {
  343. trip = <&cpu1_emerg>;
  344. cooling-device = <&cpu0 3 3>,
  345. <&cpu1 3 3>;
  346. };
  347. };
  348. };
  349. ap_thermal_cpu2: ap-thermal-cpu2 {
  350. polling-delay-passive = <1000>;
  351. polling-delay = <1000>;
  352. thermal-sensors = <&ap_thermal 3>;
  353. trips {
  354. cpu2_hot: cpu2-hot {
  355. temperature = <85000>;
  356. hysteresis = <2000>;
  357. type = "passive";
  358. };
  359. cpu2_emerg: cpu2-emerg {
  360. temperature = <95000>;
  361. hysteresis = <2000>;
  362. type = "passive";
  363. };
  364. };
  365. cooling-maps {
  366. map2_hot: map2-hot {
  367. trip = <&cpu2_hot>;
  368. cooling-device = <&cpu2 1 2>,
  369. <&cpu3 1 2>;
  370. };
  371. map2_emerg: map2-emerg {
  372. trip = <&cpu2_emerg>;
  373. cooling-device = <&cpu2 3 3>,
  374. <&cpu3 3 3>;
  375. };
  376. };
  377. };
  378. ap_thermal_cpu3: ap-thermal-cpu3 {
  379. polling-delay-passive = <1000>;
  380. polling-delay = <1000>;
  381. thermal-sensors = <&ap_thermal 4>;
  382. trips {
  383. cpu3_hot: cpu3-hot {
  384. temperature = <85000>;
  385. hysteresis = <2000>;
  386. type = "passive";
  387. };
  388. cpu3_emerg: cpu3-emerg {
  389. temperature = <95000>;
  390. hysteresis = <2000>;
  391. type = "passive";
  392. };
  393. };
  394. cooling-maps {
  395. map3_hot: map3-bhot {
  396. trip = <&cpu3_hot>;
  397. cooling-device = <&cpu2 1 2>,
  398. <&cpu3 1 2>;
  399. };
  400. map3_emerg: map3-emerg {
  401. trip = <&cpu3_emerg>;
  402. cooling-device = <&cpu2 3 3>,
  403. <&cpu3 3 3>;
  404. };
  405. };
  406. };
  407. };
  408. };