ipq8071-ap8220.dts 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335
  1. // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
  2. /dts-v1/;
  3. #include "ipq8074.dtsi"
  4. #include "ipq8074-ac-cpu.dtsi"
  5. #include "ipq8074-ess.dtsi"
  6. #include <dt-bindings/gpio/gpio.h>
  7. #include <dt-bindings/input/input.h>
  8. #include <dt-bindings/leds/common.h>
  9. / {
  10. model = "Aliyun AP8220";
  11. compatible = "aliyun,ap8220", "qcom,ipq8074";
  12. aliases {
  13. serial0 = &blsp1_uart5;
  14. led-boot = &led_power;
  15. led-failsafe = &led_power;
  16. led-running = &led_power;
  17. led-upgrade = &led_power;
  18. };
  19. chosen {
  20. stdout-path = "serial0:115200n8";
  21. bootargs-append = " root=/dev/ubiblock0_1";
  22. };
  23. keys {
  24. compatible = "gpio-keys";
  25. pinctrl-0 = <&button_pins>;
  26. pinctrl-names = "default";
  27. reset {
  28. label = "reset";
  29. linux,code = <KEY_RESTART>;
  30. gpios = <&tlmm 66 GPIO_ACTIVE_LOW>;
  31. };
  32. };
  33. leds {
  34. compatible = "gpio-leds";
  35. led_power: power {
  36. color = <LED_COLOR_ID_GREEN>;
  37. function = LED_FUNCTION_POWER;
  38. gpios = <&tlmm 46 GPIO_ACTIVE_HIGH>;
  39. };
  40. wlan2g {
  41. color = <LED_COLOR_ID_GREEN>;
  42. function = LED_FUNCTION_WLAN_2GHZ;
  43. gpios = <&tlmm 47 GPIO_ACTIVE_HIGH>;
  44. linux,default-trigger = "phy1radio";
  45. };
  46. wlan5g {
  47. color = <LED_COLOR_ID_GREEN>;
  48. function = LED_FUNCTION_WLAN_5GHZ;
  49. gpios = <&tlmm 48 GPIO_ACTIVE_HIGH>;
  50. linux,default-trigger = "phy0radio";
  51. };
  52. bluetooth {
  53. color = <LED_COLOR_ID_GREEN>;
  54. function = LED_FUNCTION_BLUETOOTH;
  55. gpios = <&tlmm 50 GPIO_ACTIVE_HIGH>;
  56. };
  57. };
  58. gpio-export {
  59. compatible = "gpio-export";
  60. ble-power {
  61. gpio-export,name = "ble_power";
  62. gpio-export,output = <1>;
  63. gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
  64. };
  65. };
  66. };
  67. &tlmm {
  68. mdio_pins: mdio-pins {
  69. mdc {
  70. pins = "gpio68";
  71. function = "mdc";
  72. drive-strength = <8>;
  73. bias-pull-up;
  74. };
  75. mdio {
  76. pins = "gpio69";
  77. function = "mdio";
  78. drive-strength = <8>;
  79. bias-pull-up;
  80. };
  81. };
  82. button_pins: button-pins {
  83. mux {
  84. pins = "gpio66";
  85. function = "gpio";
  86. drive-strength = <8>;
  87. bias-pull-up;
  88. };
  89. };
  90. };
  91. &blsp1_spi1 {
  92. status = "okay";
  93. flash@0 {
  94. compatible = "jedec,spi-nor";
  95. reg = <0>;
  96. spi-max-frequency = <50000000>;
  97. partitions {
  98. compatible = "fixed-partitions";
  99. #address-cells = <1>;
  100. #size-cells = <1>;
  101. partition@0 {
  102. label = "0:sbl1";
  103. reg = <0x0 0x50000>;
  104. read-only;
  105. };
  106. partition@50000 {
  107. label = "0:mibib";
  108. reg = <0x50000 0x10000>;
  109. read-only;
  110. };
  111. partition@60000 {
  112. label = "0:qsee";
  113. reg = <0x60000 0x180000>;
  114. read-only;
  115. };
  116. partition@1e0000 {
  117. label = "0:devcfg";
  118. reg = <0x1e0000 0x10000>;
  119. read-only;
  120. };
  121. partition@1f0000 {
  122. label = "0:apdp";
  123. reg = <0x1f0000 0x10000>;
  124. read-only;
  125. };
  126. partition@200000 {
  127. label = "0:rpm";
  128. reg = <0x200000 0x40000>;
  129. read-only;
  130. };
  131. partition@240000 {
  132. label = "0:cdt";
  133. reg = <0x240000 0x10000>;
  134. read-only;
  135. };
  136. partition@250000 {
  137. label = "0:appsblenv";
  138. reg = <0x250000 0x10000>;
  139. };
  140. partition@260000 {
  141. label = "0:appsbl";
  142. reg = <0x260000 0xa0000>;
  143. read-only;
  144. };
  145. partition@300000 {
  146. label = "0:art";
  147. reg = <0x300000 0x40000>;
  148. read-only;
  149. };
  150. partition@340000 {
  151. label = "0:ethphyfw";
  152. reg = <0x340000 0x80000>;
  153. read-only;
  154. };
  155. partition@3c0000 {
  156. label = "product_info";
  157. reg = <0x3c0000 0x10000>;
  158. read-only;
  159. };
  160. partition@3d0000 {
  161. label = "mtdoops";
  162. reg = <0x3d0000 0x20000>;
  163. };
  164. partition@3f0000 {
  165. label = "priv_data1";
  166. reg = <0x3f0000 0x10000>;
  167. read-only;
  168. };
  169. };
  170. };
  171. };
  172. &blsp1_uart5 {
  173. status = "okay";
  174. };
  175. &cryptobam {
  176. status = "okay";
  177. };
  178. &crypto {
  179. status = "okay";
  180. };
  181. &prng {
  182. status = "okay";
  183. };
  184. &qpic_bam {
  185. status = "okay";
  186. };
  187. &qusb_phy_0 {
  188. status = "okay";
  189. };
  190. &ssphy_0 {
  191. status = "okay";
  192. };
  193. &usb_0 {
  194. status = "okay";
  195. };
  196. &qpic_nand {
  197. status = "okay";
  198. nand@0 {
  199. reg = <0>;
  200. nand-ecc-strength = <4>;
  201. nand-ecc-step-size = <512>;
  202. nand-bus-width = <8>;
  203. partitions {
  204. compatible = "fixed-partitions";
  205. #address-cells = <1>;
  206. #size-cells = <1>;
  207. partition@0 {
  208. label = "rootfs1";
  209. reg = <0x0000000 0x3000000>;
  210. };
  211. partition@3000000 {
  212. label = "rootfs2";
  213. reg = <0x3000000 0x3000000>;
  214. };
  215. partition@6000000 {
  216. label = "usrdata";
  217. reg = <0x6000000 0x2000000>;
  218. };
  219. };
  220. };
  221. };
  222. &mdio {
  223. status = "okay";
  224. pinctrl-0 = <&mdio_pins>;
  225. pinctrl-names = "default";
  226. qca8081_24: ethernet-phy@24 {
  227. compatible = "ethernet-phy-id004d.d101";
  228. reg = <24>;
  229. reset-deassert-us = <10000>;
  230. reset-gpios = <&tlmm 33 GPIO_ACTIVE_LOW>;
  231. };
  232. qca8081_28: ethernet-phy@28 {
  233. compatible = "ethernet-phy-id004d.d101";
  234. reg = <28>;
  235. reset-deassert-us = <10000>;
  236. reset-gpios = <&tlmm 44 GPIO_ACTIVE_LOW>;
  237. };
  238. };
  239. &switch {
  240. status = "okay";
  241. switch_lan_bmp = <ESS_PORT5>;
  242. switch_wan_bmp = <ESS_PORT6>;
  243. switch_mac_mode1 = <MAC_MODE_SGMII_PLUS>;
  244. switch_mac_mode2 = <MAC_MODE_SGMII_PLUS>;
  245. qcom,port_phyinfo {
  246. port@5 {
  247. port_id = <5>;
  248. phy_address = <24>;
  249. port_mac_sel = "QGMAC_PORT";
  250. };
  251. port@6 {
  252. port_id = <6>;
  253. phy_address = <28>;
  254. port_mac_sel = "QGMAC_PORT";
  255. };
  256. };
  257. };
  258. &edma {
  259. status = "okay";
  260. };
  261. &dp5 {
  262. status = "okay";
  263. phy-mode = "sgmii";
  264. phy-handle = <&qca8081_24>;
  265. label = "wan";
  266. };
  267. &dp6 {
  268. status = "okay";
  269. phy-handle = <&qca8081_28>;
  270. label = "lan";
  271. };
  272. &wifi {
  273. status = "okay";
  274. qcom,ath11k-calibration-variant = "Aliyun-AP8220";
  275. };