qcom-ipq4028-wpj428.dts 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316
  1. /* Copyright (c) 2015, The Linux Foundation. All rights reserved.
  2. * Copyright (c) 2017, Christian Mehlis <[email protected]>
  3. * Copyright (c) 2017-2018, Sven Eckelmann <[email protected]>
  4. *
  5. * Permission to use, copy, modify, and/or distribute this software for any
  6. * purpose with or without fee is hereby granted, provided that the above
  7. * copyright notice and this permission notice appear in all copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  10. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  11. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  12. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  13. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  14. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  15. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  16. *
  17. */
  18. #include "qcom-ipq4019.dtsi"
  19. #include <dt-bindings/gpio/gpio.h>
  20. #include <dt-bindings/input/input.h>
  21. #include <dt-bindings/soc/qcom,tcsr.h>
  22. / {
  23. model = "Compex WPJ428";
  24. compatible = "compex,wpj428";
  25. chosen {
  26. /*
  27. * There's a chance that SPI reads fail even though the data itself is alright.
  28. * The read result is cached and squashfs can't recover.
  29. * Just panic when that happens and hope that next time it doesn't.
  30. */
  31. bootargs-append = " rootflags=errors=panic";
  32. };
  33. soc {
  34. rng@22000 {
  35. status = "okay";
  36. };
  37. mdio@90000 {
  38. status = "okay";
  39. pinctrl-0 = <&mdio_pins>;
  40. pinctrl-names = "default";
  41. reset-gpios = <&tlmm 59 GPIO_ACTIVE_LOW>;
  42. reset-delay-us = <2000>;
  43. };
  44. tcsr@194b000 {
  45. /* select hostmode */
  46. compatible = "qcom,tcsr";
  47. reg = <0x194b000 0x100>;
  48. qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
  49. status = "okay";
  50. };
  51. tcsr@1949000 {
  52. compatible = "qcom,tcsr";
  53. reg = <0x1949000 0x100>;
  54. qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
  55. };
  56. ess_tcsr@1953000 {
  57. compatible = "qcom,tcsr";
  58. reg = <0x1953000 0x1000>;
  59. qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
  60. };
  61. tcsr@1957000 {
  62. compatible = "qcom,tcsr";
  63. reg = <0x1957000 0x100>;
  64. qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
  65. };
  66. usb2: usb2@60f8800 {
  67. status = "okay";
  68. };
  69. usb3: usb3@8af8800 {
  70. status = "okay";
  71. };
  72. crypto@8e3a000 {
  73. status = "okay";
  74. };
  75. watchdog@b017000 {
  76. status = "okay";
  77. };
  78. };
  79. keys {
  80. compatible = "gpio-keys";
  81. reset {
  82. label = "reset";
  83. gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
  84. linux,code = <KEY_RESTART>;
  85. };
  86. };
  87. aliases {
  88. led-boot = &status;
  89. led-failsafe = &status;
  90. led-upgrade = &status;
  91. };
  92. leds {
  93. compatible = "gpio-leds";
  94. status: rss4 {
  95. label = "green:rss4";
  96. gpios = <&tlmm 5 GPIO_ACTIVE_HIGH>;
  97. };
  98. rss3 {
  99. label = "green:rss3";
  100. gpios = <&tlmm 4 GPIO_ACTIVE_HIGH>;
  101. };
  102. };
  103. beeper: beeper {
  104. compatible = "gpio-beeper";
  105. gpios = <&tlmm 58 GPIO_ACTIVE_HIGH>;
  106. };
  107. };
  108. &tlmm {
  109. mdio_pins: mdio_pinmux {
  110. mux_1 {
  111. pins = "gpio53";
  112. function = "mdio";
  113. bias-pull-up;
  114. };
  115. mux_2 {
  116. pins = "gpio52";
  117. function = "mdc";
  118. bias-pull-up;
  119. };
  120. };
  121. serial_pins: serial_pinmux {
  122. mux {
  123. pins = "gpio60", "gpio61";
  124. function = "blsp_uart0";
  125. bias-disable;
  126. };
  127. };
  128. spi_0_pins: spi_0_pinmux {
  129. pin {
  130. function = "blsp_spi0";
  131. pins = "gpio55", "gpio56", "gpio57";
  132. drive-strength = <12>;
  133. bias-disable;
  134. };
  135. pin_cs {
  136. function = "gpio";
  137. pins = "gpio54";
  138. drive-strength = <2>;
  139. bias-disable;
  140. output-high;
  141. };
  142. };
  143. };
  144. &blsp_dma {
  145. status = "okay";
  146. };
  147. &blsp1_spi1 {
  148. pinctrl-0 = <&spi_0_pins>;
  149. pinctrl-names = "default";
  150. status = "okay";
  151. cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
  152. m25p80@0 {
  153. compatible = "jedec,spi-nor";
  154. reg = <0>;
  155. spi-max-frequency = <24000000>;
  156. partitions {
  157. compatible = "fixed-partitions";
  158. #address-cells = <1>;
  159. #size-cells = <1>;
  160. partition0@0 {
  161. label = "0:SBL1";
  162. reg = <0x00000000 0x00040000>;
  163. read-only;
  164. };
  165. partition1@40000 {
  166. label = "0:MIBIB";
  167. reg = <0x00040000 0x00020000>;
  168. read-only;
  169. };
  170. partition2@60000 {
  171. label = "0:QSEE";
  172. reg = <0x00060000 0x00060000>;
  173. read-only;
  174. };
  175. partition3@c0000 {
  176. label = "0:CDT";
  177. reg = <0x000c0000 0x00010000>;
  178. read-only;
  179. };
  180. partition4@d0000 {
  181. label = "0:DDRPARAMS";
  182. reg = <0x000d0000 0x00010000>;
  183. read-only;
  184. };
  185. partition5@e0000 {
  186. label = "0:APPSBLENV"; /* uboot env*/
  187. reg = <0x000e0000 0x00010000>;
  188. read-only;
  189. };
  190. partition5@f0000 {
  191. label = "0:APPSBL"; /* uboot */
  192. reg = <0x000f0000 0x00080000>;
  193. read-only;
  194. };
  195. partition5@170000 {
  196. label = "0:ART";
  197. reg = <0x00170000 0x00010000>;
  198. read-only;
  199. nvmem-layout {
  200. compatible = "fixed-layout";
  201. #address-cells = <1>;
  202. #size-cells = <1>;
  203. macaddr_art_e010: mac-address@e010 {
  204. reg = <0xe010 0x6>;
  205. };
  206. macaddr_art_e018: mac-address@e018 {
  207. reg = <0xe018 0x6>;
  208. };
  209. precal_art_1000: precal@1000 {
  210. reg = <0x1000 0x2f20>;
  211. };
  212. precal_art_5000: precal@5000 {
  213. reg = <0x5000 0x2f20>;
  214. };
  215. };
  216. };
  217. partition6@180000 {
  218. compatible = "denx,fit";
  219. label = "firmware";
  220. reg = <0x00180000 0x01e80000>;
  221. };
  222. };
  223. };
  224. };
  225. &blsp1_uart1 {
  226. pinctrl-0 = <&serial_pins>;
  227. pinctrl-names = "default";
  228. status = "okay";
  229. };
  230. &cryptobam {
  231. status = "okay";
  232. };
  233. &gmac {
  234. status = "okay";
  235. };
  236. &switch {
  237. status = "okay";
  238. };
  239. &swport4 {
  240. status = "okay";
  241. label = "lan1";
  242. nvmem-cells = <&macaddr_art_e018>;
  243. nvmem-cell-names = "mac-address";
  244. };
  245. &swport5 {
  246. status = "okay";
  247. label = "lan2";
  248. nvmem-cells = <&macaddr_art_e010>;
  249. nvmem-cell-names = "mac-address";
  250. };
  251. &usb3_ss_phy {
  252. status = "okay";
  253. };
  254. &usb3_hs_phy {
  255. status = "okay";
  256. };
  257. &usb2_hs_phy {
  258. status = "okay";
  259. };
  260. &wifi0 {
  261. status = "okay";
  262. nvmem-cell-names = "pre-calibration";
  263. nvmem-cells = <&precal_art_1000>;
  264. };
  265. &wifi1 {
  266. status = "okay";
  267. nvmem-cell-names = "pre-calibration";
  268. nvmem-cells = <&precal_art_5000>;
  269. };