ar9331.dtsi 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. // SPDX-License-Identifier: GPL-2.0
  2. #include <dt-bindings/clock/ath79-clk.h>
  3. / {
  4. compatible = "qca,ar9331";
  5. #address-cells = <1>;
  6. #size-cells = <1>;
  7. cpus {
  8. #address-cells = <1>;
  9. #size-cells = <0>;
  10. cpu@0 {
  11. device_type = "cpu";
  12. compatible = "mips,mips24Kc";
  13. clocks = <&pll ATH79_CLK_CPU>;
  14. reg = <0>;
  15. };
  16. };
  17. cpuintc: interrupt-controller {
  18. compatible = "qca,ar7100-cpu-intc";
  19. interrupt-controller;
  20. #interrupt-cells = <1>;
  21. qca,ddr-wb-channel-interrupts = <2>, <3>;
  22. qca,ddr-wb-channels = <&ddr_ctrl 3>, <&ddr_ctrl 2>;
  23. };
  24. ref: ref {
  25. compatible = "fixed-clock";
  26. #clock-cells = <0>;
  27. };
  28. ahb {
  29. compatible = "simple-bus";
  30. ranges;
  31. #address-cells = <1>;
  32. #size-cells = <1>;
  33. interrupt-parent = <&cpuintc>;
  34. apb {
  35. compatible = "simple-bus";
  36. ranges;
  37. #address-cells = <1>;
  38. #size-cells = <1>;
  39. interrupt-parent = <&miscintc>;
  40. ddr_ctrl: memory-controller@18000000 {
  41. compatible = "qca,ar7240-ddr-controller";
  42. reg = <0x18000000 0x100>;
  43. #qca,ddr-wb-channel-cells = <1>;
  44. };
  45. uart: serial@18020000 {
  46. compatible = "qca,ar9330-uart";
  47. reg = <0x18020000 0x14>;
  48. interrupts = <3>;
  49. clocks = <&ref>;
  50. clock-names = "uart";
  51. status = "disabled";
  52. };
  53. gpio: gpio@18040000 {
  54. compatible = "qca,ar7100-gpio";
  55. reg = <0x18040000 0x34>;
  56. interrupts = <2>;
  57. ngpios = <30>;
  58. gpio-controller;
  59. #gpio-cells = <2>;
  60. interrupt-controller;
  61. #interrupt-cells = <2>;
  62. status = "disabled";
  63. };
  64. pll: pll-controller@18050000 {
  65. compatible = "qca,ar9330-pll";
  66. reg = <0x18050000 0x100>;
  67. clocks = <&ref>;
  68. clock-names = "ref";
  69. #clock-cells = <1>;
  70. };
  71. miscintc: interrupt-controller@18060010 {
  72. compatible = "qca,ar7240-misc-intc";
  73. reg = <0x18060010 0x8>;
  74. interrupt-parent = <&cpuintc>;
  75. interrupts = <6>;
  76. interrupt-controller;
  77. #interrupt-cells = <1>;
  78. };
  79. rst: reset-controller@1806001c {
  80. compatible = "qca,ar7100-reset";
  81. reg = <0x1806001c 0x4>;
  82. #reset-cells = <1>;
  83. };
  84. };
  85. eth0: ethernet@19000000 {
  86. compatible = "qca,ar9330-eth";
  87. reg = <0x19000000 0x200>;
  88. interrupts = <4>;
  89. resets = <&rst 9>, <&rst 22>;
  90. reset-names = "mac", "mdio";
  91. clocks = <&pll ATH79_CLK_AHB>, <&pll ATH79_CLK_AHB>;
  92. clock-names = "eth", "mdio";
  93. phy-mode = "mii";
  94. phy-handle = <&phy_port4>;
  95. status = "disabled";
  96. };
  97. eth1: ethernet@1a000000 {
  98. compatible = "qca,ar9330-eth";
  99. reg = <0x1a000000 0x200>;
  100. interrupts = <5>;
  101. resets = <&rst 13>, <&rst 23>;
  102. reset-names = "mac", "mdio";
  103. clocks = <&pll ATH79_CLK_AHB>, <&pll ATH79_CLK_AHB>;
  104. clock-names = "eth", "mdio";
  105. phy-mode = "gmii";
  106. status = "disabled";
  107. fixed-link {
  108. speed = <1000>;
  109. full-duplex;
  110. pause;
  111. };
  112. mdio {
  113. #address-cells = <1>;
  114. #size-cells = <0>;
  115. switch10: switch@10 {
  116. #address-cells = <1>;
  117. #size-cells = <0>;
  118. compatible = "qca,ar9331-switch";
  119. reg = <0x10>;
  120. resets = <&rst 8>;
  121. reset-names = "switch";
  122. interrupt-parent = <&miscintc>;
  123. interrupts = <12>;
  124. interrupt-controller;
  125. #interrupt-cells = <1>;
  126. ports {
  127. #address-cells = <1>;
  128. #size-cells = <0>;
  129. switch_port0: port@0 {
  130. reg = <0x0>;
  131. ethernet = <&eth1>;
  132. phy-mode = "gmii";
  133. fixed-link {
  134. speed = <1000>;
  135. full-duplex;
  136. pause;
  137. };
  138. };
  139. switch_port1: port@1 {
  140. reg = <0x1>;
  141. phy-handle = <&phy_port0>;
  142. phy-mode = "internal";
  143. status = "disabled";
  144. };
  145. switch_port2: port@2 {
  146. reg = <0x2>;
  147. phy-handle = <&phy_port1>;
  148. phy-mode = "internal";
  149. status = "disabled";
  150. };
  151. switch_port3: port@3 {
  152. reg = <0x3>;
  153. phy-handle = <&phy_port2>;
  154. phy-mode = "internal";
  155. status = "disabled";
  156. };
  157. switch_port4: port@4 {
  158. reg = <0x4>;
  159. phy-handle = <&phy_port3>;
  160. phy-mode = "internal";
  161. status = "disabled";
  162. };
  163. };
  164. mdio {
  165. #address-cells = <1>;
  166. #size-cells = <0>;
  167. interrupt-parent = <&switch10>;
  168. phy_port0: phy@0 {
  169. reg = <0x0>;
  170. interrupts = <0>;
  171. status = "disabled";
  172. };
  173. phy_port1: phy@1 {
  174. reg = <0x1>;
  175. interrupts = <0>;
  176. status = "disabled";
  177. };
  178. phy_port2: phy@2 {
  179. reg = <0x2>;
  180. interrupts = <0>;
  181. status = "disabled";
  182. };
  183. phy_port3: phy@3 {
  184. reg = <0x3>;
  185. interrupts = <0>;
  186. status = "disabled";
  187. };
  188. phy_port4: phy@4 {
  189. reg = <0x4>;
  190. interrupts = <0>;
  191. status = "disabled";
  192. };
  193. };
  194. };
  195. };
  196. };
  197. usb: usb@1b000100 {
  198. compatible = "chipidea,usb2";
  199. reg = <0x1b000000 0x200>;
  200. interrupts = <3>;
  201. resets = <&rst 5>;
  202. phy-names = "usb-phy";
  203. phys = <&usb_phy>;
  204. status = "disabled";
  205. };
  206. spi: spi@1f000000 {
  207. compatible = "qca,ar7100-spi";
  208. reg = <0x1f000000 0x10>;
  209. clocks = <&pll ATH79_CLK_AHB>;
  210. clock-names = "ahb";
  211. #address-cells = <1>;
  212. #size-cells = <0>;
  213. status = "disabled";
  214. };
  215. };
  216. usb_phy: usb-phy {
  217. compatible = "qca,ar7100-usb-phy";
  218. reset-names = "phy", "suspend-override";
  219. resets = <&rst 4>, <&rst 3>;
  220. #phy-cells = <0>;
  221. status = "disabled";
  222. };
  223. };