ipq8072-haze.dts 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347
  1. // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
  2. /dts-v1/;
  3. #include "ipq8074.dtsi"
  4. #include "ipq8074-hk-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 = "prpl Foundation Haze";
  11. compatible = "prpl,haze", "qcom,ipq8074";
  12. aliases {
  13. serial0 = &blsp1_uart5;
  14. /* Aliases are required by U-Boot to patch MAC addresses */
  15. ethernet0 = &dp6_syn;
  16. ethernet1 = &dp4;
  17. ethernet2 = &dp3;
  18. ethernet3 = &dp2;
  19. label-mac-device = &dp6_syn;
  20. led-boot = &led_system_blue;
  21. led-failsafe = &led_system_red;
  22. led-running = &led_system_green;
  23. led-upgrade = &led_system_blue;
  24. };
  25. chosen {
  26. stdout-path = "serial0:115200n8";
  27. };
  28. keys {
  29. compatible = "gpio-keys";
  30. pinctrl-0 = <&button_pins>;
  31. pinctrl-names = "default";
  32. wps-button {
  33. label = "wps";
  34. gpios = <&tlmm 42 GPIO_ACTIVE_LOW>;
  35. linux,code = <KEY_WPS_BUTTON>;
  36. };
  37. reset-button {
  38. label = "reset";
  39. gpios = <&tlmm 44 GPIO_ACTIVE_LOW>;
  40. linux,code = <KEY_RESTART>;
  41. };
  42. };
  43. };
  44. &tlmm {
  45. mdio_pins: mdio-state {
  46. mdc-pins {
  47. pins = "gpio68";
  48. function = "mdc";
  49. drive-strength = <8>;
  50. bias-pull-up;
  51. };
  52. mdio-pins {
  53. pins = "gpio69";
  54. function = "mdio";
  55. drive-strength = <8>;
  56. bias-pull-up;
  57. };
  58. };
  59. button_pins: button-state {
  60. wps-pins {
  61. pins = "gpio42";
  62. function = "gpio";
  63. drive-strength = <8>;
  64. bias-pull-up;
  65. };
  66. rst-pins {
  67. pins = "gpio44";
  68. function = "gpio";
  69. drive-strength = <8>;
  70. bias-pull-up;
  71. };
  72. };
  73. i2c_3_pins: i2c-3-state {
  74. pins = "gpio46", "gpio47";
  75. function = "blsp2_i2c";
  76. drive-strength = <8>;
  77. bias-disable;
  78. };
  79. };
  80. &blsp1_uart5 {
  81. status = "okay";
  82. };
  83. &prng {
  84. status = "okay";
  85. };
  86. &ssphy_0 {
  87. status = "okay";
  88. };
  89. &qusb_phy_0 {
  90. status = "okay";
  91. };
  92. &ssphy_1 {
  93. status = "okay";
  94. };
  95. &qusb_phy_1 {
  96. status = "okay";
  97. };
  98. &usb_0 {
  99. status = "okay";
  100. };
  101. &usb_1 {
  102. status = "okay";
  103. };
  104. &cryptobam {
  105. status = "okay";
  106. };
  107. &crypto {
  108. status = "okay";
  109. };
  110. &qpic_bam {
  111. status = "okay";
  112. };
  113. &blsp1_spi1 { /* BLSP1 QUP1 */
  114. pinctrl-0 = <&spi_0_pins>;
  115. pinctrl-names = "default";
  116. status = "okay";
  117. flash@0 {
  118. reg = <0>;
  119. compatible = "jedec,spi-nor";
  120. spi-max-frequency = <50000000>;
  121. partitions {
  122. compatible = "qcom,smem-part";
  123. };
  124. };
  125. };
  126. &mdio {
  127. status = "okay";
  128. pinctrl-0 = <&mdio_pins>;
  129. pinctrl-names = "default";
  130. reset-gpios = <&tlmm 22 GPIO_ACTIVE_LOW>;
  131. ethernet-phy-package@0 {
  132. #address-cells = <1>;
  133. #size-cells = <0>;
  134. compatible = "qcom,qca8075-package";
  135. reg = <0>;
  136. qca8075_0: ethernet-phy@0 {
  137. compatible = "ethernet-phy-ieee802.3-c22";
  138. reg = <0>;
  139. };
  140. qca8075_1: ethernet-phy@1 {
  141. compatible = "ethernet-phy-ieee802.3-c22";
  142. reg = <1>;
  143. };
  144. qca8075_2: ethernet-phy@2 {
  145. compatible = "ethernet-phy-ieee802.3-c22";
  146. reg = <2>;
  147. };
  148. qca8075_3: ethernet-phy@3 {
  149. compatible = "ethernet-phy-ieee802.3-c22";
  150. reg = <3>;
  151. };
  152. };
  153. aqr113c: ethernet-phy@5 {
  154. compatible ="ethernet-phy-ieee802.3-c45";
  155. reg = <8>;
  156. reset-gpios = <&tlmm 43 GPIO_ACTIVE_LOW>;
  157. };
  158. };
  159. &sdhc_1 {
  160. status = "okay";
  161. vqmmc-supply = <&l11>;
  162. };
  163. &switch {
  164. status = "okay";
  165. switch_lan_bmp = <(ESS_PORT1 | ESS_PORT2 | ESS_PORT3 | ESS_PORT4)>; /* lan port bitmap */
  166. switch_wan_bmp = <ESS_PORT6>; /* wan port bitmap */
  167. switch_mac_mode = <MAC_MODE_PSGMII>; /* mac mode for uniphy instance0*/
  168. switch_mac_mode1 = <MAC_MODE_10GBASE_R>; /* mac mode for uniphy instance1*/
  169. switch_mac_mode2 = <MAC_MODE_USXGMII>; /* mac mode for uniphy instance2*/
  170. qcom,port_phyinfo {
  171. port@1 {
  172. port_id = <1>;
  173. phy_address = <0>;
  174. };
  175. port@2 {
  176. port_id = <2>;
  177. phy_address = <1>;
  178. };
  179. port@3 {
  180. port_id = <3>;
  181. phy_address = <2>;
  182. };
  183. port@4 {
  184. port_id = <4>;
  185. phy_address = <3>;
  186. };
  187. port@6 {
  188. port_id = <6>;
  189. phy_address = <8>;
  190. compatible = "ethernet-phy-ieee802.3-c45";
  191. ethernet-phy-ieee802.3-c45;
  192. };
  193. };
  194. };
  195. &edma {
  196. status = "okay";
  197. };
  198. /* Dummy LAN port */
  199. &dp1 {
  200. status = "disabled";
  201. phy-handle = <&qca8075_0>;
  202. label = "lan4";
  203. };
  204. &dp2 {
  205. status = "okay";
  206. phy-handle = <&qca8075_1>;
  207. label = "lan3";
  208. };
  209. &dp3 {
  210. status = "okay";
  211. phy-handle = <&qca8075_2>;
  212. label = "lan2";
  213. };
  214. &dp4 {
  215. status = "okay";
  216. phy-handle = <&qca8075_3>;
  217. label = "lan1";
  218. };
  219. &dp6_syn {
  220. status = "okay";
  221. qcom,mactype = <1>;
  222. phy-mode = "usxgmii";
  223. phy-handle = <&aqr113c>;
  224. label = "wan";
  225. };
  226. &pcie_qmp0 {
  227. status = "okay";
  228. };
  229. &pcie0 {
  230. status = "okay";
  231. perst-gpios = <&tlmm 58 GPIO_ACTIVE_LOW>;
  232. };
  233. &pcie_qmp1 {
  234. status = "okay";
  235. };
  236. &pcie1 {
  237. status = "okay";
  238. perst-gpios = <&tlmm 61 GPIO_ACTIVE_LOW>;
  239. pcie@0 {
  240. wifi@0,0 {
  241. status = "okay";
  242. /* ath11k has no DT compatible for PCI cards */
  243. compatible = "pci17cb,1104";
  244. reg = <0x00010000 0 0 0 0>;
  245. qcom,ath11k-calibration-variant = "prpl-Haze";
  246. };
  247. };
  248. };
  249. &wifi {
  250. status = "okay";
  251. qcom,ath11k-calibration-variant = "prpl-Haze";
  252. };
  253. &blsp1_i2c3{
  254. pinctrl-0 = <&i2c_3_pins>;
  255. pinctrl-names = "default";
  256. status = "okay";
  257. led-controller@30 {
  258. compatible = "ti,lp5562";
  259. reg = <0x30>;
  260. clock-mode = /bits/ 8 <2>;
  261. #address-cells = <1>;
  262. #size-cells = <0>;
  263. led_system_red: chan@0 {
  264. chan-name = "red";
  265. led-cur = /bits/ 8 <0x20>;
  266. max-cur = /bits/ 8 <0x60>;
  267. color = <LED_COLOR_ID_RED>;
  268. reg = <0>;
  269. };
  270. led_system_green: chan@1 {
  271. chan-name = "green";
  272. led-cur = /bits/ 8 <0x20>;
  273. max-cur = /bits/ 8 <0x60>;
  274. color = <LED_COLOR_ID_GREEN>;
  275. reg = <1>;
  276. };
  277. led_system_blue: chan@2 {
  278. chan-name = "blue";
  279. led-cur = /bits/ 8 <0x20>;
  280. max-cur = /bits/ 8 <0x60>;
  281. color = <LED_COLOR_ID_BLUE>;
  282. reg = <2>;
  283. };
  284. };
  285. };