qcom-ipq4018-wap-ac.dts 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  1. // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
  2. /* Copyright (c) 2020, Robert Marko <[email protected]> */
  3. #include "qcom-ipq4019.dtsi"
  4. #include <dt-bindings/gpio/gpio.h>
  5. #include <dt-bindings/input/input.h>
  6. #include <dt-bindings/soc/qcom,tcsr.h>
  7. / {
  8. model = "MikroTik wAP ac";
  9. compatible = "mikrotik,wap-ac";
  10. memory {
  11. device_type = "memory";
  12. reg = <0x80000000 0x08000000>;
  13. };
  14. chosen {
  15. stdout-path = "serial0:115200n8";
  16. };
  17. aliases {
  18. led-boot = &led_user;
  19. led-failsafe = &led_user;
  20. led-running = &led_user;
  21. led-upgrade = &led_user;
  22. };
  23. soc {
  24. counter@4a1000 {
  25. compatible = "qcom,qca-gcnt";
  26. reg = <0x4a1000 0x4>;
  27. };
  28. tcsr@1949000 {
  29. compatible = "qcom,tcsr";
  30. reg = <0x1949000 0x100>;
  31. qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
  32. };
  33. ess_tcsr@1953000 {
  34. compatible = "qcom,tcsr";
  35. reg = <0x1953000 0x1000>;
  36. qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
  37. };
  38. tcsr@1957000 {
  39. compatible = "qcom,tcsr";
  40. reg = <0x1957000 0x100>;
  41. qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
  42. };
  43. ess-switch@c000000 {
  44. status = "okay";
  45. };
  46. edma@c080000 {
  47. status = "okay";
  48. };
  49. };
  50. keys {
  51. compatible = "gpio-keys";
  52. reset {
  53. label = "reset";
  54. gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
  55. linux,code = <KEY_RESTART>;
  56. };
  57. };
  58. leds {
  59. compatible = "gpio-leds";
  60. power {
  61. label = "blue:power";
  62. gpios = <&tlmm 0 GPIO_ACTIVE_HIGH>;
  63. default-state = "keep";
  64. };
  65. led_user: user {
  66. label = "green:user";
  67. gpios = <&tlmm 3 GPIO_ACTIVE_HIGH>;
  68. panic-indicator;
  69. };
  70. };
  71. };
  72. &prng {
  73. status = "okay";
  74. };
  75. &tlmm {
  76. serial_pins: serial_pinmux {
  77. mux {
  78. pins = "gpio60", "gpio61";
  79. function = "blsp_uart0";
  80. bias-disable;
  81. };
  82. };
  83. spi_0_pins: spi_0_pinmux {
  84. pin {
  85. function = "blsp_spi0";
  86. pins = "gpio55", "gpio56", "gpio57";
  87. drive-strength = <2>;
  88. bias-disable;
  89. };
  90. pin_cs {
  91. function = "gpio";
  92. pins = "gpio54";
  93. drive-strength = <2>;
  94. bias-disable;
  95. output-high;
  96. };
  97. };
  98. };
  99. &blsp_dma {
  100. status = "okay";
  101. };
  102. &blsp1_spi1 {
  103. status = "okay";
  104. pinctrl-0 = <&spi_0_pins>;
  105. pinctrl-names = "default";
  106. cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
  107. flash@0 {
  108. reg = <0>;
  109. compatible = "jedec,spi-nor";
  110. spi-max-frequency = <40000000>;
  111. partitions {
  112. compatible = "fixed-partitions";
  113. #address-cells = <1>;
  114. #size-cells = <1>;
  115. partition@0 {
  116. label = "Qualcomm";
  117. reg = <0x0 0x80000>;
  118. read-only;
  119. };
  120. partition@80000 {
  121. compatible = "mikrotik,routerboot-partitions";
  122. #address-cells = <1>;
  123. #size-cells = <1>;
  124. label = "RouterBoot";
  125. reg = <0x80000 0x80000>;
  126. hard_config {
  127. read-only;
  128. size = <0x2000>;
  129. };
  130. dtb_config {
  131. read-only;
  132. };
  133. soft_config {
  134. };
  135. };
  136. partition@100000 {
  137. compatible = "mikrotik,minor";
  138. label = "firmware";
  139. reg = <0x100000 0xf00000>;
  140. };
  141. };
  142. };
  143. };
  144. &blsp1_uart1 {
  145. status = "okay";
  146. pinctrl-0 = <&serial_pins>;
  147. pinctrl-names = "default";
  148. };
  149. &cryptobam {
  150. status = "okay";
  151. };
  152. &crypto {
  153. status = "okay";
  154. };
  155. &watchdog {
  156. status = "okay";
  157. };
  158. &mdio {
  159. status = "okay";
  160. };
  161. &gmac0 {
  162. qcom,phy_mdio_addr = <4>;
  163. qcom,poll_required = <1>;
  164. qcom,forced_speed = <1000>;
  165. qcom,forced_duplex = <1>;
  166. vlan_tag = <2 0x20>;
  167. };
  168. &gmac1 {
  169. qcom,phy_mdio_addr = <3>;
  170. vlan_tag = <1 0x10>;
  171. };
  172. &wifi0 {
  173. status = "okay";
  174. qcom,ath10k-calibration-variant = "MikroTik-wAP-ac";
  175. };
  176. &wifi1 {
  177. status = "okay";
  178. qcom,ath10k-calibration-variant = "MikroTik-wAP-ac";
  179. };