qcom-ipq4029-mr33.dts 7.5 KB

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