qcom-ipq4018-a42.dts 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. // SPDX-License-Identifier: ISC
  2. /* Copyright (c) 2015, The Linux Foundation. All rights reserved.
  3. * Copyright (c) 2017, Sven Eckelmann <[email protected]>
  4. */
  5. #include "qcom-ipq4019.dtsi"
  6. #include <dt-bindings/gpio/gpio.h>
  7. #include <dt-bindings/input/input.h>
  8. #include <dt-bindings/soc/qcom,tcsr.h>
  9. / {
  10. model = "OpenMesh A42";
  11. compatible = "openmesh,a42";
  12. soc {
  13. rng@22000 {
  14. status = "okay";
  15. };
  16. tcsr@194b000 {
  17. /* select hostmode */
  18. compatible = "qcom,tcsr";
  19. reg = <0x194b000 0x100>;
  20. qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
  21. status = "okay";
  22. };
  23. tcsr@1949000 {
  24. compatible = "qcom,tcsr";
  25. reg = <0x1949000 0x100>;
  26. qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
  27. };
  28. ess_tcsr@1953000 {
  29. compatible = "qcom,tcsr";
  30. reg = <0x1953000 0x1000>;
  31. qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
  32. };
  33. tcsr@1957000 {
  34. compatible = "qcom,tcsr";
  35. reg = <0x1957000 0x100>;
  36. qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
  37. };
  38. usb2: usb2@60f8800 {
  39. status = "okay";
  40. };
  41. crypto@8e3a000 {
  42. status = "okay";
  43. };
  44. watchdog@b017000 {
  45. status = "okay";
  46. };
  47. };
  48. keys {
  49. compatible = "gpio-keys";
  50. reset {
  51. label = "reset";
  52. gpios = <&tlmm 59 GPIO_ACTIVE_LOW>;
  53. linux,code = <KEY_RESTART>;
  54. };
  55. };
  56. aliases {
  57. led-boot = &led_status_green;
  58. led-failsafe = &led_status_green;
  59. led-running = &led_status_green;
  60. led-upgrade = &led_status_green;
  61. label-mac-device = &swport5;
  62. };
  63. leds {
  64. compatible = "gpio-leds";
  65. status_red {
  66. label = "red:status";
  67. gpios = <&tlmm 0 GPIO_ACTIVE_HIGH>;
  68. };
  69. led_status_green: status_green {
  70. label = "green:status";
  71. gpios = <&tlmm 1 GPIO_ACTIVE_HIGH>;
  72. };
  73. status_blue {
  74. label = "blue:status";
  75. gpios = <&tlmm 2 GPIO_ACTIVE_HIGH>;
  76. };
  77. };
  78. watchdog {
  79. compatible = "linux,wdt-gpio";
  80. gpios = <&tlmm 5 GPIO_ACTIVE_LOW>;
  81. hw_algo = "toggle";
  82. /* hw_margin_ms is actually 300s but driver limits it to 60s */
  83. hw_margin_ms = <60000>;
  84. always-running;
  85. };
  86. };
  87. &tlmm {
  88. serial_pins: serial_pinmux {
  89. mux {
  90. pins = "gpio60", "gpio61";
  91. function = "blsp_uart0";
  92. bias-disable;
  93. };
  94. };
  95. spi_0_pins: spi_0_pinmux {
  96. pin {
  97. function = "blsp_spi0";
  98. pins = "gpio55", "gpio56", "gpio57";
  99. drive-strength = <12>;
  100. bias-disable;
  101. };
  102. pin_cs {
  103. function = "gpio";
  104. pins = "gpio54";
  105. drive-strength = <2>;
  106. bias-disable;
  107. output-high;
  108. };
  109. };
  110. };
  111. &blsp_dma {
  112. status = "okay";
  113. };
  114. &blsp1_spi1 {
  115. pinctrl-0 = <&spi_0_pins>;
  116. pinctrl-names = "default";
  117. status = "okay";
  118. cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
  119. flash@0 {
  120. #address-cells = <1>;
  121. #size-cells = <1>;
  122. compatible = "jedec,spi-nor";
  123. reg = <0>;
  124. spi-max-frequency = <24000000>;
  125. /* partitions are passed via bootloader */
  126. partitions {
  127. partition-art {
  128. compatible = "nvmem-cells";
  129. #address-cells = <1>;
  130. #size-cells = <1>;
  131. label = "0:ART";
  132. precal_art_1000: precal@1000 {
  133. reg = <0x1000 0x2f20>;
  134. };
  135. precal_art_5000: precal@5000 {
  136. reg = <0x5000 0x2f20>;
  137. };
  138. macaddr_gmac0: macaddr@0 {
  139. reg = <0x0 0x6>;
  140. };
  141. macaddr_gmac1: macaddr@6 {
  142. reg = <0x6 0x6>;
  143. };
  144. };
  145. };
  146. };
  147. };
  148. &blsp1_uart1 {
  149. pinctrl-0 = <&serial_pins>;
  150. pinctrl-names = "default";
  151. status = "okay";
  152. };
  153. &cryptobam {
  154. status = "okay";
  155. };
  156. &usb2_hs_phy {
  157. status = "okay";
  158. };
  159. &mdio {
  160. status = "okay";
  161. };
  162. &gmac {
  163. status = "okay";
  164. };
  165. &switch {
  166. status = "okay";
  167. };
  168. &swport4 {
  169. status = "okay";
  170. label = "ethernet2";
  171. nvmem-cell-names = "mac-address";
  172. nvmem-cells = <&macaddr_gmac1>;
  173. };
  174. &swport5 {
  175. status = "okay";
  176. label = "ethernet1";
  177. nvmem-cell-names = "mac-address";
  178. nvmem-cells = <&macaddr_gmac0>;
  179. };
  180. &wifi0 {
  181. status = "okay";
  182. qcom,ath10k-calibration-variant = "OM-A42";
  183. nvmem-cell-names = "pre-calibration";
  184. nvmem-cells = <&precal_art_1000>;
  185. };
  186. &wifi1 {
  187. status = "okay";
  188. qcom,ath10k-calibration-variant = "OM-A42";
  189. nvmem-cell-names = "pre-calibration";
  190. nvmem-cells = <&precal_art_5000>;
  191. };