qcom-ipq4018-nbg6617.dts 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322
  1. /* Copyright (c) 2015, The Linux Foundation. All rights reserved.
  2. *
  3. * Permission to use, copy, modify, and/or distribute this software for any
  4. * purpose with or without fee is hereby granted, provided that the above
  5. * copyright notice and this permission notice appear in all copies.
  6. *
  7. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  8. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  9. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  10. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  11. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  12. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  13. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  14. *
  15. */
  16. #include "qcom-ipq4019.dtsi"
  17. #include <dt-bindings/gpio/gpio.h>
  18. #include <dt-bindings/input/input.h>
  19. #include <dt-bindings/input/linux-event-codes.h>
  20. #include <dt-bindings/soc/qcom,tcsr.h>
  21. / {
  22. model = "ZyXEL NBG6617";
  23. compatible = "zyxel,nbg6617", "qcom,ipq4019";
  24. chosen {
  25. /*
  26. * the vendor u-boot adds root and mtdparts cmdline parameters
  27. * which we don't want... but we have to overwrite them or else
  28. * the kernel will take them at face value.
  29. */
  30. bootargs-append = " mtdparts= root=31:13";
  31. };
  32. aliases {
  33. led-boot = &power;
  34. led-failsafe = &power;
  35. led-running = &power;
  36. led-upgrade = &power;
  37. };
  38. soc {
  39. mdio@90000 {
  40. status = "okay";
  41. };
  42. ess-psgmii@98000 {
  43. status = "okay";
  44. };
  45. tcsr@1949000 {
  46. compatible = "qcom,tcsr";
  47. reg = <0x1949000 0x100>;
  48. qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
  49. };
  50. tcsr@194b000 {
  51. compatible = "qcom,tcsr";
  52. reg = <0x194b000 0x100>;
  53. qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
  54. };
  55. ess_tcsr@1953000 {
  56. compatible = "qcom,tcsr";
  57. reg = <0x1953000 0x1000>;
  58. qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
  59. };
  60. tcsr@1957000 {
  61. compatible = "qcom,tcsr";
  62. reg = <0x1957000 0x100>;
  63. qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
  64. };
  65. usb2@60f8800 {
  66. status = "okay";
  67. };
  68. serial@78af000 {
  69. pinctrl-0 = <&serial_pins>;
  70. pinctrl-names = "default";
  71. status = "okay";
  72. };
  73. usb3@8af8800 {
  74. status = "okay";
  75. };
  76. crypto@8e3a000 {
  77. status = "okay";
  78. };
  79. watchdog@b017000 {
  80. status = "okay";
  81. };
  82. ess-switch@c000000 {
  83. status = "okay";
  84. };
  85. edma@c080000 {
  86. status = "okay";
  87. };
  88. };
  89. gpio-keys {
  90. compatible = "gpio-keys";
  91. wlan {
  92. label = "wlan";
  93. gpios = <&tlmm 2 GPIO_ACTIVE_HIGH>;
  94. linux,code = <KEY_RFKILL>;
  95. linux,input-type = <EV_SW>;
  96. };
  97. wps {
  98. label = "wps";
  99. gpios = <&tlmm 63 GPIO_ACTIVE_LOW>;
  100. linux,code = <KEY_WPS_BUTTON>;
  101. };
  102. reset {
  103. label = "reset";
  104. gpios = <&tlmm 4 GPIO_ACTIVE_LOW>;
  105. linux,code = <KEY_RESTART>;
  106. };
  107. };
  108. gpio-leds {
  109. compatible = "gpio-leds";
  110. pinctrl-0 = <&led_pins>;
  111. pinctrl-names = "default";
  112. power: power {
  113. label = "nbg6617:green:power";
  114. gpios = <&tlmm 3 GPIO_ACTIVE_HIGH>;
  115. };
  116. usb {
  117. label = "nbg6617:green:usb";
  118. gpios = <&tlmm 0 GPIO_ACTIVE_HIGH>;
  119. };
  120. wlan2G {
  121. label = "nbg6617:green:wlan2G";
  122. gpios = <&tlmm 58 GPIO_ACTIVE_HIGH>;
  123. };
  124. wlan5G {
  125. label = "nbg6617:green:wlan5G";
  126. gpios = <&tlmm 5 GPIO_ACTIVE_HIGH>;
  127. };
  128. wps {
  129. label = "nbg6617:green:wps";
  130. gpios = <&tlmm 1 GPIO_ACTIVE_HIGH>;
  131. };
  132. };
  133. };
  134. &tlmm {
  135. serial_pins: serial_pinmux {
  136. mux {
  137. pins = "gpio60", "gpio61";
  138. function = "blsp_uart0";
  139. bias-disable;
  140. };
  141. };
  142. spi_0_pins: spi_0_pinmux {
  143. mux {
  144. function = "blsp_spi0";
  145. pins = "gpio55", "gpio56", "gpio57";
  146. drive-strength = <12>;
  147. bias-disable;
  148. };
  149. mux_cs {
  150. function = "gpio";
  151. pins = "gpio54";
  152. drive-strength = <2>;
  153. bias-disable;
  154. output-low;
  155. };
  156. };
  157. led_pins: led_pinmux {
  158. mux {
  159. pins = "gpio0", "gpio1", "gpio3", "gpio5", "gpio58";
  160. drive-strength = <0x8>;
  161. bias-disable;
  162. output-low;
  163. };
  164. };
  165. };
  166. &blsp1_spi1 { /* BLSP1 QUP1 */
  167. pinctrl-0 = <&spi_0_pins>;
  168. pinctrl-names = "default";
  169. status = "okay";
  170. cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
  171. mx25l25635f@0 {
  172. compatible = "mx25l25635f", "jedec,spi-nor";
  173. #address-cells = <1>;
  174. #size-cells = <0>;
  175. reg = <0>;
  176. spi-max-frequency = <24000000>;
  177. status = "okay";
  178. m25p,fast-read;
  179. partitions {
  180. compatible = "fixed-partitions";
  181. #address-cells = <1>;
  182. #size-cells = <1>;
  183. partition0@0 {
  184. label = "SBL1";
  185. reg = <0x00000000 0x00040000>;
  186. read-only;
  187. };
  188. partition1@40000 {
  189. label = "MIBIB";
  190. reg = <0x00040000 0x00020000>;
  191. read-only;
  192. };
  193. partition2@60000 {
  194. label = "QSEE";
  195. reg = <0x00060000 0x00060000>;
  196. read-only;
  197. };
  198. partition3@c0000 {
  199. label = "CDT";
  200. reg = <0x000c0000 0x00010000>;
  201. read-only;
  202. };
  203. partition4@d0000 {
  204. label = "DDRPARAMS";
  205. reg = <0x000d0000 0x00010000>;
  206. read-only;
  207. };
  208. partition5@e0000 {
  209. label = "APPSBL"; /* u-boot */
  210. reg = <0x000e0000 0x00080000>;
  211. /* U-Boot Standalone App "zloader" is located at 0x64000 */
  212. read-only;
  213. };
  214. partition6@160000 {
  215. label = "APPSBLENV"; /* u-boot env */
  216. reg = <0x00160000 0x00010000>;
  217. };
  218. partition7@170000 {
  219. /* make a backup of this partition! */
  220. label = "ART";
  221. reg = <0x00170000 0x00010000>;
  222. read-only;
  223. };
  224. partition8@180000 {
  225. label = "kernel";
  226. reg = <0x00180000 0x00400000>;
  227. };
  228. partition9@580000 {
  229. label = "dualflag";
  230. reg = <0x00580000 0x00010000>;
  231. read-only;
  232. };
  233. partition10@590000 {
  234. label = "header";
  235. reg = <0x00590000 0x00010000>;
  236. };
  237. partition11@5a0000 {
  238. label = "romd";
  239. reg = <0x005a0000 0x00100000>;
  240. read-only;
  241. };
  242. partition12@6a0000 {
  243. label = "not_root_data";
  244. /*
  245. * for some strange reason, someone at ZyXEL
  246. * had the "great" idea to put the rootfs_data
  247. * in front of rootfs... Don't do that!
  248. * As a result this one, full MebiByte remains
  249. * unused.
  250. */
  251. reg = <0x006a0000 0x00100000>;
  252. };
  253. partition13@7a0000 {
  254. label = "rootfs";
  255. reg = <0x007a0000 0x01860000>;
  256. };
  257. };
  258. };
  259. };
  260. &cryptobam {
  261. status = "okay";
  262. };
  263. &blsp_dma {
  264. status = "okay";
  265. };
  266. &wifi0 {
  267. status = "okay";
  268. qcom,ath10k-calibration-variant = "ZyXEL-NBG6617";
  269. };
  270. &wifi1 {
  271. status = "okay";
  272. qcom,ath10k-calibration-variant = "ZyXEL-NBG6617";
  273. };
  274. &usb3_ss_phy {
  275. status = "okay";
  276. };
  277. &usb3_hs_phy {
  278. status = "okay";
  279. };
  280. &usb2_hs_phy {
  281. status = "okay";
  282. };