1
0

ar9132_tplink_tl-wr941-v2.dts 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167
  1. // SPDX-License-Identifier: GPL-2.0
  2. /dts-v1/;
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/input/input.h>
  5. #include "ar9132.dtsi"
  6. / {
  7. compatible = "tplink,tl-wr941-v2", "qca,ar9132";
  8. model = "TP-Link TL-WR941N/ND v2/v3";
  9. aliases {
  10. led-boot = &led_system;
  11. led-failsafe = &led_system;
  12. led-running = &led_system;
  13. led-upgrade = &led_system;
  14. };
  15. keys {
  16. compatible = "gpio-keys";
  17. button0 {
  18. label = "reset";
  19. linux,code = <KEY_RESTART>;
  20. gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
  21. debounce-interval = <60>;
  22. };
  23. button1 {
  24. label = "qss";
  25. linux,code = <KEY_WPS_BUTTON>;
  26. gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
  27. debounce-interval = <60>;
  28. };
  29. };
  30. leds {
  31. compatible = "gpio-leds";
  32. led_system: system {
  33. label = "tp-link:green:system";
  34. gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
  35. };
  36. qss_r {
  37. label = "tp-link:red:qss";
  38. gpios = <&gpio 4 GPIO_ACTIVE_HIGH>;
  39. };
  40. qss_g {
  41. label = "tp-link:green:qss";
  42. gpios = <&gpio 5 GPIO_ACTIVE_HIGH>;
  43. };
  44. wlan {
  45. label = "tp-link:green:wlan";
  46. gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
  47. linux,default-trigger = "phy0tpt";
  48. };
  49. };
  50. dsa {
  51. compatible = "marvell,dsa";
  52. #address-cells = <1>;
  53. #size-cells = <0>;
  54. dsa,mii-bus = <&mdio0>;
  55. dsa,ethernet = <&eth0>;
  56. switch@0 {
  57. #address-cells = <1>;
  58. #size-cells = <0>;
  59. reg = <0>;
  60. port@0 {
  61. reg = <0>;
  62. label = "wan";
  63. };
  64. port@1 {
  65. reg = <1>;
  66. label = "lan1";
  67. };
  68. port@2 {
  69. reg = <2>;
  70. label = "lan2";
  71. };
  72. port@3 {
  73. reg = <3>;
  74. label = "lan3";
  75. };
  76. port@4 {
  77. reg = <4>;
  78. label = "lan4";
  79. };
  80. port@5 {
  81. reg = <5>;
  82. label = "cpu";
  83. };
  84. };
  85. };
  86. };
  87. &uart {
  88. status = "okay";
  89. };
  90. &spi {
  91. status = "okay";
  92. flash@0 {
  93. compatible = "jedec,spi-nor";
  94. reg = <0>;
  95. spi-max-frequency = <25000000>;
  96. partitions {
  97. compatible = "fixed-partitions";
  98. #address-cells = <1>;
  99. #size-cells = <1>;
  100. uboot: partition@0 {
  101. label = "u-boot";
  102. reg = <0x000000 0x20000>;
  103. read-only;
  104. };
  105. partition@20000 {
  106. compatible = "tplink,firmware";
  107. label = "firmware";
  108. reg = <0x020000 0x3d0000>;
  109. };
  110. art: partition@3f0000 {
  111. label = "art";
  112. reg = <0x3f0000 0x10000>;
  113. read-only;
  114. };
  115. };
  116. };
  117. };
  118. &mdio0 {
  119. status = "okay";
  120. };
  121. &eth0 {
  122. status = "okay";
  123. phy-mode = "rmii";
  124. mtd-mac-address = <&uboot 0x1fc00>;
  125. fixed-link {
  126. speed = <100>;
  127. full-duplex;
  128. };
  129. };
  130. &wmac {
  131. status = "okay";
  132. mtd-cal-data = <&art 0x1000>;
  133. mtd-mac-address = <&uboot 0x1fc00>;
  134. };