qcom-ipq4029-mr33.dts 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411
  1. // SPDX-License-Identifier: GPL-2.0-only
  2. /*
  3. * Device Tree Source for Meraki MR33 (Stinkbug)
  4. *
  5. * Copyright (C) 2017 Chris Blake <[email protected]>
  6. * Copyright (C) 2017 Christian Lamparter <[email protected]>
  7. *
  8. * Based on Cisco Meraki DTS from GPL release r25-linux-3.14-20170427
  9. *
  10. * This file is licensed under the terms of the GNU General Public
  11. * License version 2. This program is licensed "as is" without
  12. * any warranty of any kind, whether express or implied.
  13. */
  14. #include "qcom-ipq4019.dtsi"
  15. #include <dt-bindings/gpio/gpio.h>
  16. #include <dt-bindings/input/input.h>
  17. #include <dt-bindings/soc/qcom,tcsr.h>
  18. #include <dt-bindings/leds/common.h>
  19. / {
  20. model = "Meraki MR33 Access Point";
  21. compatible = "meraki,mr33";
  22. aliases {
  23. led-boot = &status_green;
  24. led-failsafe = &status_red;
  25. led-running = &status_green;
  26. led-upgrade = &power_orange;
  27. };
  28. /* Do we really need this defined? */
  29. memory {
  30. device_type = "memory";
  31. reg = <0x80000000 0x10000000>;
  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. };
  42. /* It is a 56-bit counter that supplies the count to the ARM arch
  43. timers and without upstream driver */
  44. counter@4a1000 {
  45. compatible = "qcom,qca-gcnt";
  46. reg = <0x4a1000 0x4>;
  47. };
  48. ess_tcsr@1953000 {
  49. compatible = "qcom,tcsr";
  50. reg = <0x1953000 0x1000>;
  51. qcom,ess-interface-select = <TCSR_ESS_PSGMII_RGMII5>;
  52. };
  53. tcsr@1949000 {
  54. compatible = "qcom,tcsr";
  55. reg = <0x1949000 0x100>;
  56. qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
  57. };
  58. tcsr@1957000 {
  59. compatible = "qcom,tcsr";
  60. reg = <0x1957000 0x100>;
  61. qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
  62. };
  63. serial@78b0000 {
  64. pinctrl-0 = <&serial_1_pins>;
  65. pinctrl-names = "default";
  66. status = "okay";
  67. bluetooth {
  68. compatible = "ti,cc2650";
  69. enable-gpios = <&tlmm 12 GPIO_ACTIVE_LOW>;
  70. };
  71. };
  72. crypto@8e3a000 {
  73. status = "okay";
  74. };
  75. watchdog@b017000 {
  76. status = "okay";
  77. };
  78. ess-switch@c000000 {
  79. switch_mac_mode = <0x3>; /* mac mode for RGMII RMII */
  80. switch_lan_bmp = <0x0>; /* lan port bitmap */
  81. switch_wan_bmp = <0x10>; /* wan port bitmap */
  82. };
  83. edma@c080000 {
  84. qcom,single-phy;
  85. qcom,num_gmac = <1>;
  86. phy-mode = "rgmii-rxid";
  87. status = "okay";
  88. };
  89. };
  90. keys {
  91. compatible = "gpio-keys";
  92. reset {
  93. label = "reset";
  94. gpios = <&tlmm 18 GPIO_ACTIVE_LOW>;
  95. linux,code = <KEY_RESTART>;
  96. };
  97. };
  98. leds {
  99. compatible = "gpio-leds";
  100. power_orange: power {
  101. label = "orange:power";
  102. gpios = <&tlmm 49 GPIO_ACTIVE_LOW>;
  103. panic-indicator;
  104. };
  105. };
  106. };
  107. &blsp_dma {
  108. status = "okay";
  109. };
  110. &blsp1_uart1 {
  111. pinctrl-0 = <&serial_0_pins>;
  112. pinctrl-names = "default";
  113. status = "okay";
  114. };
  115. &cryptobam {
  116. status = "okay";
  117. };
  118. &gmac0 {
  119. qcom,phy_mdio_addr = <1>;
  120. qcom,poll_required = <1>;
  121. vlan_tag = <0 0x20>;
  122. };
  123. &blsp1_i2c3 {
  124. pinctrl-0 = <&i2c_0_pins>;
  125. pinctrl-names = "default";
  126. status = "okay";
  127. at24@50 {
  128. compatible = "atmel,24c64";
  129. pagesize = <32>;
  130. reg = <0x50>;
  131. read-only; /* This holds our MAC & Meraki board-data */
  132. };
  133. };
  134. &blsp1_i2c4 {
  135. pinctrl-0 = <&i2c_1_pins>;
  136. pinctrl-names = "default";
  137. status = "okay";
  138. led-controller@30 {
  139. compatible = "ti,lp5562";
  140. reg = <0x30>;
  141. clock-mode = /bits/8 <2>;
  142. enable-gpio = <&tlmm 48 GPIO_ACTIVE_HIGH>;
  143. #address-cells = <1>;
  144. #size-cells = <0>;
  145. /* RGB led */
  146. status_red: chan@0 {
  147. chan-name = "red:status";
  148. led-cur = /bits/ 8 <0x20>;
  149. max-cur = /bits/ 8 <0x60>;
  150. reg = <0>;
  151. color = <LED_COLOR_ID_RED>;
  152. };
  153. status_green: chan@1 {
  154. chan-name = "green:status";
  155. led-cur = /bits/ 8 <0x20>;
  156. max-cur = /bits/ 8 <0x60>;
  157. reg = <1>;
  158. color = <LED_COLOR_ID_GREEN>;
  159. };
  160. chan@2 {
  161. chan-name = "blue:status";
  162. led-cur = /bits/ 8 <0x20>;
  163. max-cur = /bits/ 8 <0x60>;
  164. reg = <2>;
  165. color = <LED_COLOR_ID_BLUE>;
  166. };
  167. chan@3 {
  168. chan-name = "white:status";
  169. led-cur = /bits/ 8 <0x20>;
  170. max-cur = /bits/ 8 <0x60>;
  171. reg = <3>;
  172. color = <LED_COLOR_ID_WHITE>;
  173. };
  174. };
  175. };
  176. &nand {
  177. pinctrl-0 = <&nand_pins>;
  178. pinctrl-names = "default";
  179. status = "okay";
  180. nand@0 {
  181. partitions {
  182. compatible = "fixed-partitions";
  183. #address-cells = <1>;
  184. #size-cells = <1>;
  185. partition@0 {
  186. label = "sbl1";
  187. reg = <0x00000000 0x00100000>;
  188. read-only;
  189. };
  190. partition@100000 {
  191. label = "mibib";
  192. reg = <0x00100000 0x00100000>;
  193. read-only;
  194. };
  195. partition@200000 {
  196. label = "bootconfig";
  197. reg = <0x00200000 0x00100000>;
  198. read-only;
  199. };
  200. partition@300000 {
  201. label = "qsee";
  202. reg = <0x00300000 0x00100000>;
  203. read-only;
  204. };
  205. partition@400000 {
  206. label = "qsee_alt";
  207. reg = <0x00400000 0x00100000>;
  208. read-only;
  209. };
  210. partition@500000 {
  211. label = "cdt";
  212. reg = <0x00500000 0x00080000>;
  213. read-only;
  214. };
  215. partition@580000 {
  216. label = "cdt_alt";
  217. reg = <0x00580000 0x00080000>;
  218. read-only;
  219. };
  220. partition@600000 {
  221. label = "ddrparams";
  222. reg = <0x00600000 0x00080000>;
  223. read-only;
  224. };
  225. partition@700000 {
  226. label = "u-boot";
  227. reg = <0x00700000 0x00200000>;
  228. read-only;
  229. };
  230. partition@900000 {
  231. label = "u-boot-backup";
  232. reg = <0x00900000 0x00200000>;
  233. read-only;
  234. };
  235. partition@b00000 {
  236. label = "ART";
  237. reg = <0x00b00000 0x00080000>;
  238. read-only;
  239. };
  240. partition@c00000 {
  241. label = "ubi";
  242. reg = <0x00c00000 0x07000000>;
  243. /*
  244. * Do not try to allocate the remaining
  245. * 4 MiB to this ubi partition. It will
  246. * confuse the u-boot and it might not
  247. * find the kernel partition anymore.
  248. */
  249. };
  250. };
  251. };
  252. };
  253. &pcie0 {
  254. status = "okay";
  255. perst-gpio = <&tlmm 38 GPIO_ACTIVE_LOW>;
  256. wake-gpio = <&tlmm 50 GPIO_ACTIVE_LOW>;
  257. bridge@0,0 {
  258. reg = <0x00000000 0 0 0 0>;
  259. #address-cells = <3>;
  260. #size-cells = <2>;
  261. ranges;
  262. wifi2: wifi@1,0 {
  263. compatible = "qcom,ath10k";
  264. status = "okay";
  265. reg = <0x00010000 0 0 0 0>;
  266. };
  267. };
  268. };
  269. &qpic_bam {
  270. status = "okay";
  271. };
  272. &tlmm {
  273. /*
  274. * GPIO43 should be 0/1 whenever the unit is
  275. * powered through PoE or AC-Adapter.
  276. * That said, playing with this seems to
  277. * reset the AP.
  278. */
  279. mdio_pins: mdio_pinmux {
  280. mux_1 {
  281. pins = "gpio6";
  282. function = "mdio";
  283. bias-pull-up;
  284. };
  285. mux_2 {
  286. pins = "gpio7";
  287. function = "mdc";
  288. bias-pull-up;
  289. };
  290. };
  291. serial_0_pins: serial_pinmux {
  292. mux {
  293. pins = "gpio16", "gpio17";
  294. function = "blsp_uart0";
  295. bias-disable;
  296. };
  297. };
  298. serial_1_pins: serial1_pinmux {
  299. mux {
  300. /* We use the i2c-0 pins for serial_1 */
  301. pins = "gpio8", "gpio9";
  302. function = "blsp_uart1";
  303. bias-disable;
  304. };
  305. };
  306. i2c_0_pins: i2c_0_pinmux {
  307. pinmux {
  308. function = "blsp_i2c0";
  309. pins = "gpio20", "gpio21";
  310. };
  311. pinconf {
  312. pins = "gpio20", "gpio21";
  313. drive-strength = <16>;
  314. bias-disable;
  315. };
  316. };
  317. i2c_1_pins: i2c_1_pinmux {
  318. pinmux {
  319. function = "blsp_i2c1";
  320. pins = "gpio34", "gpio35";
  321. };
  322. pinconf {
  323. pins = "gpio34", "gpio35";
  324. drive-strength = <16>;
  325. bias-disable;
  326. };
  327. };
  328. nand_pins: nand_pins {
  329. /*
  330. * There are 18 pins. 15 pins are common between LCD and NAND.
  331. * The QPIC controller arbitrates between LCD and NAND. Of the
  332. * remaining 4, 2 are for NAND and 2 are for LCD exclusively.
  333. *
  334. * The meraki source hints that the bluetooth module claims
  335. * pin 52 as well. But sadly, there's no data whenever this
  336. * is a NAND or LCD exclusive pin or not.
  337. */
  338. pullups {
  339. pins = "gpio52", "gpio53", "gpio58",
  340. "gpio59";
  341. function = "qpic";
  342. bias-pull-up;
  343. };
  344. pulldowns {
  345. pins = "gpio54", "gpio55", "gpio56",
  346. "gpio57", "gpio60", "gpio61",
  347. "gpio62", "gpio63", "gpio64",
  348. "gpio65", "gpio66", "gpio67",
  349. "gpio68", "gpio69";
  350. function = "qpic";
  351. bias-pull-down;
  352. };
  353. };
  354. };
  355. &wifi0 {
  356. status = "okay";
  357. qcom,ath10k-calibration-variant = "Meraki-MR33";
  358. };
  359. &wifi1 {
  360. status = "okay";
  361. qcom,ath10k-calibration-variant = "Meraki-MR33";
  362. };