1
0

qca9558_librerouter_librerouter-v1.dts 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211
  1. // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
  2. /dts-v1/;
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/input/input.h>
  5. #include "qca9557.dtsi"
  6. / {
  7. compatible = "librerouter,librerouter-v1", "qca,qca9558";
  8. model = "LibreRouter v1";
  9. chosen {
  10. bootargs = "console=ttyS0,115200n8";
  11. };
  12. aliases {
  13. led-boot = &system;
  14. led-failsafe = &system;
  15. led-running = &system;
  16. led-upgrade = &system;
  17. };
  18. leds {
  19. compatible = "gpio-leds";
  20. system: system {
  21. label = "librerouter-v1:green:system";
  22. gpios = <&gpio 23 GPIO_ACTIVE_HIGH>;
  23. default-state = "on";
  24. };
  25. wifi_green {
  26. label = "librerouter-v1:green:wlan2g";
  27. gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
  28. linux,default-trigger = "phy0tpt";
  29. };
  30. status_blue {
  31. label = "librerouter-v1:blue:status";
  32. gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
  33. };
  34. };
  35. button {
  36. compatible = "gpio-keys";
  37. reset {
  38. label = "Reset";
  39. linux,code = <KEY_RESTART>;
  40. gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
  41. debounce-interval = <60>;
  42. };
  43. };
  44. watchdog {
  45. compatible = "linux,wdt-gpio";
  46. gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
  47. hw_algo = "toggle";
  48. hw_margin_ms = <1000>;
  49. always-running;
  50. };
  51. };
  52. &pcie0 {
  53. status = "okay";
  54. wifi@0,0 {
  55. compatible = "pci168c,0033";
  56. reg = <0x0000 0 0 0 0>;
  57. };
  58. };
  59. &pcie1 {
  60. status = "okay";
  61. wifi@0,0 {
  62. compatible = "pci168c,0033";
  63. reg = <0x0000 0 0 0 0>;
  64. };
  65. };
  66. &uart {
  67. status = "okay";
  68. };
  69. &gpio {
  70. status = "okay";
  71. };
  72. &usb_phy0 {
  73. status = "okay";
  74. };
  75. &usb0 {
  76. #address-cells = <1>;
  77. #size-cells = <0>;
  78. status = "okay";
  79. };
  80. &usb_phy1 {
  81. status = "okay";
  82. };
  83. &usb1 {
  84. #address-cells = <1>;
  85. #size-cells = <0>;
  86. status = "okay";
  87. };
  88. &spi {
  89. status = "okay";
  90. num-cs = <1>;
  91. flash@0 {
  92. compatible = "jedec,spi-nor";
  93. reg = <0>;
  94. spi-max-frequency = <25000000>;
  95. partitions {
  96. compatible = "fixed-partitions";
  97. #address-cells = <1>;
  98. #size-cells = <1>;
  99. partition@0 {
  100. label = "u-boot";
  101. reg = <0x000000 0x040000>;
  102. read-only;
  103. };
  104. partition@40000 {
  105. label = "u-boot-env";
  106. reg = <0x040000 0x010000>;
  107. };
  108. partition@50000 {
  109. compatible = "denx,uimage";
  110. label = "firmware";
  111. reg = <0x050000 0x7c0000>;
  112. };
  113. partition@810000 {
  114. label = "fw2";
  115. reg = <0x810000 0x7d0000>;
  116. };
  117. partition@fd0000 {
  118. label = "res";
  119. reg = <0xfd0000 0x20000>;
  120. };
  121. art: partition@ff0000 {
  122. label = "art";
  123. reg = <0xff0000 0x010000>;
  124. read-only;
  125. };
  126. };
  127. };
  128. };
  129. &mdio0 {
  130. status = "okay";
  131. phy0: ethernet-phy@0 {
  132. reg = <0>;
  133. qca,ar8327-initvals = <
  134. 0x04 0x87600000 /* PORT0: RGMII, MAC0/6 exchage, tx_delay 01, rx_delay 10 */
  135. 0x0c 0x00000080 /* PORT6: SGMII */
  136. 0x10 0x81000080 /* POWER_ON_STRAP: LED open drain, SerDes auto-neg disabled */
  137. 0x50 0xcf37cf37 /* LED_CTRL0 */
  138. 0x54 0xcf37cf37 /* LED_CTRL1 */
  139. 0x58 0xcf37cf37 /* LED_CTRL2 */
  140. 0x5c 0x0 /* LED_CTRL3 */
  141. 0x7c 0x0000007e /* PORT0_STATUS */
  142. 0x94 0x0000007e /* PORT6 STATUS */
  143. >;
  144. };
  145. };
  146. &eth0 {
  147. status = "okay";
  148. pll-data = <0xa6000000 0x00000101 0x00001616>;
  149. mtd-mac-address = <&art 0x0>;
  150. phy-handle = <&phy0>;
  151. };
  152. &eth1 {
  153. status = "okay";
  154. phy-mode = "sgmii";
  155. pll-data = <0x03000101 0x00000101 0x00001616>;
  156. mtd-mac-address = <&art 0x6>;
  157. fixed-link {
  158. speed = <1000>;
  159. full-duplex;
  160. };
  161. };
  162. &wmac {
  163. status = "okay";
  164. mtd-cal-data = <&art 0x1000>;
  165. mtd-mac-address = <&art 0xc>;
  166. };