fvp-base-psci-common.dtsi 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252
  1. // SPDX-License-Identifier: GPL-2.0 or BSD-3-Clause
  2. /*
  3. * ARM Ltd. Fast Models
  4. *
  5. * Architecture Envelope Model (AEM) ARMv8-A
  6. * ARMAEMv8AMPCT
  7. *
  8. * RTSM_VE_AEMv8A.lisa
  9. *
  10. * Copyright (c) 2017-2021, ARM Limited and Contributors. All rights reserved.
  11. */
  12. #include <dt-bindings/interrupt-controller/arm-gic.h>
  13. #include <services/sdei_flags.h>
  14. #define LEVEL 0
  15. #define EDGE 2
  16. #define SDEI_NORMAL 0x70
  17. #define HIGHEST_SEC 0
  18. #include "rtsm_ve-motherboard.dtsi"
  19. / {
  20. model = "FVP Base";
  21. compatible = "arm,fvp-base", "arm,vexpress";
  22. interrupt-parent = <&gic>;
  23. #address-cells = <2>;
  24. #size-cells = <2>;
  25. chosen {
  26. stdout-path = "serial0:115200n8";
  27. #if (ENABLE_RME == 1)
  28. bootargs = "console=ttyAMA0 earlycon=pl011,0x1c090000 root=/dev/vda ip=on";
  29. #endif
  30. };
  31. aliases {
  32. serial0 = &v2m_serial0;
  33. serial1 = &v2m_serial1;
  34. serial2 = &v2m_serial2;
  35. serial3 = &v2m_serial3;
  36. };
  37. psci {
  38. compatible = "arm,psci-1.0", "arm,psci-0.2";
  39. method = "smc";
  40. max-pwr-lvl = <2>;
  41. };
  42. #if SDEI_IN_FCONF || SEC_INT_DESC_IN_FCONF
  43. firmware {
  44. #if SDEI_IN_FCONF
  45. sdei {
  46. compatible = "arm,sdei-1.0";
  47. method = "smc";
  48. private_event_count = <3>;
  49. shared_event_count = <3>;
  50. /*
  51. * Each event descriptor has typically 3 fields:
  52. * 1. Event number
  53. * 2. Interrupt number the event is bound to or
  54. * if event is dynamic, specified as SDEI_DYN_IRQ
  55. * 3. Bit map of event flags
  56. */
  57. private_events = <1000 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>,
  58. <1001 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>,
  59. <1002 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>;
  60. shared_events = <2000 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>,
  61. <2001 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>,
  62. <2002 SDEI_DYN_IRQ SDEI_MAPF_DYNAMIC>;
  63. };
  64. #endif /* SDEI_IN_FCONF */
  65. #if SEC_INT_DESC_IN_FCONF
  66. sec_interrupts {
  67. compatible = "arm,secure_interrupt_desc";
  68. /* Number of G0 and G1 secure interrupts defined by the platform */
  69. g0_intr_cnt = <2>;
  70. g1s_intr_cnt = <9>;
  71. /*
  72. * Define a list of Group 1 Secure and Group 0 interrupts as per GICv3
  73. * terminology. Each interrupt property descriptor has 3 fields:
  74. * 1. Interrupt number
  75. * 2. Interrupt priority
  76. * 3. Type of interrupt (Edge or Level configured)
  77. */
  78. g0_intr_desc = < 8 SDEI_NORMAL EDGE>,
  79. <14 HIGHEST_SEC EDGE>;
  80. g1s_intr_desc = < 9 HIGHEST_SEC EDGE>,
  81. <10 HIGHEST_SEC EDGE>,
  82. <11 HIGHEST_SEC EDGE>,
  83. <12 HIGHEST_SEC EDGE>,
  84. <13 HIGHEST_SEC EDGE>,
  85. <15 HIGHEST_SEC EDGE>,
  86. <29 HIGHEST_SEC LEVEL>,
  87. <56 HIGHEST_SEC LEVEL>,
  88. <57 HIGHEST_SEC LEVEL>;
  89. };
  90. #endif /* SEC_INT_DESC_IN_FCONF */
  91. };
  92. #endif /* SDEI_IN_FCONF || SEC_INT_DESC_IN_FCONF */
  93. cpus {
  94. #address-cells = <2>;
  95. #size-cells = <0>;
  96. CPU_MAP
  97. idle-states {
  98. entry-method = "psci";
  99. CPU_SLEEP_0: cpu-sleep-0 {
  100. compatible = "arm,idle-state";
  101. local-timer-stop;
  102. arm,psci-suspend-param = <0x0010000>;
  103. entry-latency-us = <40>;
  104. exit-latency-us = <100>;
  105. min-residency-us = <150>;
  106. };
  107. CLUSTER_SLEEP_0: cluster-sleep-0 {
  108. compatible = "arm,idle-state";
  109. local-timer-stop;
  110. arm,psci-suspend-param = <0x1010000>;
  111. entry-latency-us = <500>;
  112. exit-latency-us = <1000>;
  113. min-residency-us = <2500>;
  114. };
  115. };
  116. CPUS
  117. L2_0: l2-cache0 {
  118. compatible = "cache";
  119. };
  120. };
  121. memory@80000000 {
  122. device_type = "memory";
  123. #if (ENABLE_RME == 1)
  124. reg = <0x00000000 0x80000000 0 0x7C000000>,
  125. <0x00000008 0x80000000 0 0x80000000>;
  126. #else
  127. reg = <0x00000000 0x80000000 0 0x7F000000>,
  128. <0x00000008 0x80000000 0 0x80000000>;
  129. #endif
  130. };
  131. reserved-memory {
  132. #address-cells = <2>;
  133. #size-cells = <2>;
  134. ranges;
  135. /* Chipselect 2,00000000 is physically at 0x18000000 */
  136. vram: vram@18000000 {
  137. /* 8 MB of designated video RAM */
  138. compatible = "shared-dma-pool";
  139. reg = <0x00000000 0x18000000 0 0x00800000>;
  140. no-map;
  141. };
  142. };
  143. timer {
  144. compatible = "arm,armv8-timer";
  145. interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>,
  146. <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>,
  147. <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>,
  148. <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>;
  149. clock-frequency = <100000000>;
  150. };
  151. timer@2a810000 {
  152. compatible = "arm,armv7-timer-mem";
  153. reg = <0x0 0x2a810000 0x0 0x10000>;
  154. clock-frequency = <100000000>;
  155. #address-cells = <1>;
  156. #size-cells = <1>;
  157. ranges = <0x0 0x0 0x2a810000 0x100000>;
  158. frame@2a830000 {
  159. frame-number = <1>;
  160. interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
  161. reg = <0x20000 0x10000>;
  162. };
  163. };
  164. pmu {
  165. compatible = "arm,armv8-pmuv3";
  166. interrupts = <GIC_PPI 7 IRQ_TYPE_LEVEL_HIGH>;
  167. };
  168. panel {
  169. compatible = "arm,rtsm-display";
  170. port {
  171. panel_in: endpoint {
  172. remote-endpoint = <&clcd_pads>;
  173. };
  174. };
  175. };
  176. bus@8000000 {
  177. #interrupt-cells = <1>;
  178. interrupt-map-mask = <0 0 63>;
  179. interrupt-map = <0 0 0 &gic 0 GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>,
  180. <0 0 1 &gic 0 GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>,
  181. <0 0 2 &gic 0 GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>,
  182. <0 0 3 &gic 0 GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>,
  183. <0 0 4 &gic 0 GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>,
  184. <0 0 5 &gic 0 GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>,
  185. <0 0 6 &gic 0 GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>,
  186. <0 0 7 &gic 0 GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>,
  187. <0 0 8 &gic 0 GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>,
  188. <0 0 9 &gic 0 GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>,
  189. <0 0 10 &gic 0 GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>,
  190. <0 0 11 &gic 0 GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>,
  191. <0 0 12 &gic 0 GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>,
  192. <0 0 13 &gic 0 GIC_SPI 13 IRQ_TYPE_LEVEL_HIGH>,
  193. <0 0 14 &gic 0 GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>,
  194. <0 0 15 &gic 0 GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>,
  195. <0 0 16 &gic 0 GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>,
  196. <0 0 17 &gic 0 GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>,
  197. <0 0 18 &gic 0 GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>,
  198. <0 0 19 &gic 0 GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>,
  199. <0 0 20 &gic 0 GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>,
  200. <0 0 21 &gic 0 GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>,
  201. <0 0 22 &gic 0 GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>,
  202. <0 0 23 &gic 0 GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>,
  203. <0 0 24 &gic 0 GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>,
  204. <0 0 25 &gic 0 GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>,
  205. <0 0 26 &gic 0 GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>,
  206. <0 0 27 &gic 0 GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>,
  207. <0 0 28 &gic 0 GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>,
  208. <0 0 29 &gic 0 GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>,
  209. <0 0 30 &gic 0 GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>,
  210. <0 0 31 &gic 0 GIC_SPI 31 IRQ_TYPE_LEVEL_HIGH>,
  211. <0 0 32 &gic 0 GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>,
  212. <0 0 33 &gic 0 GIC_SPI 33 IRQ_TYPE_LEVEL_HIGH>,
  213. <0 0 34 &gic 0 GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>,
  214. <0 0 35 &gic 0 GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>,
  215. <0 0 36 &gic 0 GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>,
  216. <0 0 37 &gic 0 GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>,
  217. <0 0 38 &gic 0 GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>,
  218. <0 0 39 &gic 0 GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>,
  219. <0 0 40 &gic 0 GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>,
  220. <0 0 41 &gic 0 GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>,
  221. <0 0 42 &gic 0 GIC_SPI 42 IRQ_TYPE_LEVEL_HIGH>,
  222. <0 0 43 &gic 0 GIC_SPI 43 IRQ_TYPE_LEVEL_HIGH>,
  223. <0 0 44 &gic 0 GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>,
  224. <0 0 46 &gic 0 GIC_SPI 46 IRQ_TYPE_LEVEL_HIGH>;
  225. };
  226. };