WHR-300HP2.dts 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. /dts-v1/;
  2. #include "mt7620a.dtsi"
  3. #include <dt-bindings/input/input.h>
  4. / {
  5. compatible = "ralink,mt7620a-soc";
  6. model = "Buffalo WHR-300HP2";
  7. gpio-leds {
  8. compatible = "gpio-leds";
  9. power {
  10. label = "whr-300hp2:red:power";
  11. gpios = <&gpio0 7 1>;
  12. };
  13. wifi {
  14. label = "whr-300hp2:green:wifi";
  15. gpios = <&gpio0 8 1>;
  16. };
  17. power2 {
  18. label = "whr-300hp2:green:power";
  19. gpios = <&gpio0 9 1>;
  20. };
  21. wifi2 {
  22. label = "whr-300hp2:orange:wifi";
  23. gpios = <&gpio0 10 1>;
  24. };
  25. internet {
  26. label = "whr-300hp2:green:internet";
  27. gpios = <&gpio2 17 1>;
  28. };
  29. router {
  30. label = "whr-300hp2:green:router";
  31. gpios = <&gpio2 18 1>;
  32. };
  33. router2 {
  34. label = "whr-300hp2:orange:router";
  35. gpios = <&gpio2 19 1>;
  36. };
  37. };
  38. gpio-keys-polled {
  39. compatible = "gpio-keys-polled";
  40. #address-cells = <1>;
  41. #size-cells = <0>;
  42. poll-interval = <20>;
  43. reset {
  44. label = "reset";
  45. gpios = <&gpio2 12 1>;
  46. linux,code = <KEY_RESTART>;
  47. };
  48. aoss {
  49. label = "aoss";
  50. gpios = <&gpio2 13 1>;
  51. linux,code = <KEY_WPS_BUTTON>;
  52. };
  53. ap {
  54. label = "ap";
  55. gpios = <&gpio2 14 1>;
  56. linux,code = <BTN_0>;
  57. linux,input-type = <EV_SW>;
  58. };
  59. bridge {
  60. label = "bridge";
  61. gpios = <&gpio2 15 1>;
  62. linux,code = <BTN_0>;
  63. linux,input-type = <EV_SW>;
  64. };
  65. };
  66. };
  67. &gpio2 {
  68. status = "okay";
  69. };
  70. &spi0 {
  71. status = "okay";
  72. m25p80@0 {
  73. #address-cells = <1>;
  74. #size-cells = <1>;
  75. compatible = "jedec,spi-nor";
  76. reg = <0>;
  77. linux,modalias = "m25p80", "s25fl064k";
  78. spi-max-frequency = <10000000>;
  79. partition@0 {
  80. label = "u-boot";
  81. reg = <0x0 0x30000>;
  82. read-only;
  83. };
  84. partition@30000 {
  85. label = "u-boot-env";
  86. reg = <0x30000 0x10000>;
  87. read-only;
  88. };
  89. factory: partition@40000 {
  90. label = "factory";
  91. reg = <0x40000 0x10000>;
  92. read-only;
  93. };
  94. partition@50000 {
  95. label = "firmware";
  96. reg = <0x50000 0x7b0000>;
  97. };
  98. };
  99. };
  100. &pinctrl {
  101. state_default: pinctrl0 {
  102. gpio {
  103. ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
  104. ralink,function = "gpio";
  105. };
  106. pa {
  107. ralink,group = "pa";
  108. ralink,function = "pa";
  109. };
  110. };
  111. };
  112. &ethernet {
  113. pinctrl-names = "default";
  114. pinctrl-0 = <&ephy_pins>;
  115. mediatek,portmap = "llllw";
  116. };
  117. &gsw {
  118. mediatek,port4 = "ephy";
  119. };
  120. &wmac {
  121. ralink,mtd-eeprom = <&factory 0>;
  122. };