ArcherC50.dts 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187
  1. /dts-v1/;
  2. #include <dt-bindings/input/input.h>
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include "mt7620a.dtsi"
  5. / {
  6. compatible = "ralink,mt7620a-soc";
  7. model = "TP-Link Archer C50";
  8. chosen {
  9. bootargs = "console=ttyS0,115200";
  10. };
  11. gpio-leds {
  12. compatible = "gpio-leds";
  13. lan {
  14. label = "c50:green:lan";
  15. gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
  16. };
  17. power {
  18. label = "c50:green:power";
  19. gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
  20. };
  21. usb {
  22. label = "c50:green:usb";
  23. gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
  24. };
  25. wan {
  26. label = "c50:green:wan";
  27. gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
  28. };
  29. wan_orange {
  30. label = "c50:orange:wan";
  31. gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
  32. };
  33. wlan5g {
  34. label = "c50:green:wlan5g";
  35. gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
  36. };
  37. wlan2g {
  38. label = "c50:green:wlan2g";
  39. gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
  40. };
  41. wps {
  42. label = "c50:green:wps";
  43. gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
  44. };
  45. };
  46. gpio-keys-polled {
  47. compatible = "gpio-keys-polled";
  48. #address-cells = <1>;
  49. #size-cells = <0>;
  50. poll-interval = <20>;
  51. reset {
  52. label = "reset";
  53. gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
  54. linux,code = <KEY_RESTART>;
  55. };
  56. rfkill {
  57. label = "rfkill";
  58. gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
  59. linux,code = <KEY_RFKILL>;
  60. }; };
  61. };
  62. &gpio1 {
  63. status = "okay";
  64. };
  65. &gpio2 {
  66. status = "okay";
  67. };
  68. &gpio3 {
  69. status = "okay";
  70. };
  71. &spi0 {
  72. status = "okay";
  73. m25p80@0 {
  74. #address-cells = <1>;
  75. #size-cells = <1>;
  76. compatible = "jedec,spi-nor";
  77. reg = <0>;
  78. linux,modalias = "m25p80", "mx25l6405d";
  79. spi-max-frequency = <10000000>;
  80. partition@0 {
  81. label = "u-boot";
  82. reg = <0x0 0x20000>;
  83. read-only;
  84. };
  85. partition@20000 {
  86. label = "firmware";
  87. reg = <0x20000 0x7a0000>;
  88. };
  89. partition@7c0000 {
  90. label = "config";
  91. reg = <0x7c0000 0x10000>;
  92. read-only;
  93. };
  94. rom: partition@7d0000 {
  95. label = "rom";
  96. reg = <0x7d0000 0x10000>;
  97. read-only;
  98. };
  99. partition@7e0000 {
  100. label = "romfile";
  101. reg = <0x7e0000 0x10000>;
  102. read-only;
  103. };
  104. radio: partition@7f0000 {
  105. label = "radio";
  106. reg = <0x7f0000 0x10000>;
  107. read-only;
  108. };
  109. };
  110. };
  111. &pinctrl {
  112. state_default: pinctrl0 {
  113. gpio {
  114. ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "ephy", "spi refclk", "mdio", "wdt", "nd_sd";
  115. ralink,function = "gpio";
  116. };
  117. pa {
  118. ralink,group = "pa";
  119. ralink,function = "pa";
  120. };
  121. };
  122. };
  123. &ethernet {
  124. pinctrl-names = "default";
  125. mtd-mac-address = <&rom 0xf100>;
  126. mediatek,portmap = "wllll";
  127. };
  128. &ehci {
  129. status = "okay";
  130. };
  131. &ohci {
  132. status = "okay";
  133. };
  134. &gsw {
  135. mediatek,port4 = "ephy";
  136. };
  137. &wmac {
  138. ralink,mtd-eeprom = <&radio 0>;
  139. };
  140. &pcie {
  141. status = "okay";
  142. pcie-bridge {
  143. mt76@0,0 {
  144. reg = <0x0000 0 0 0 0>;
  145. device_type = "pci";
  146. mediatek,mtd-eeprom = <&radio 32768>;
  147. mediatek,2ghz = <0>;
  148. mtd-mac-address = <&rom 0xf100>;
  149. mtd-mac-address-increment = <(-1)>;
  150. };
  151. };
  152. };