GL-MT300A.dts 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. /dts-v1/;
  2. #include "mt7620a.dtsi"
  3. #include <dt-bindings/input/input.h>
  4. / {
  5. compatible = "GL-MT300A", "ralink,mt7620a-soc";
  6. model = "GL-MT300A";
  7. chosen {
  8. bootargs = "console=ttyS0,115200";
  9. };
  10. gpio-leds {
  11. compatible = "gpio-leds";
  12. wan {
  13. label = "gl-mt300a:wan";
  14. gpios = <&gpio2 0 1>;
  15. };
  16. lan {
  17. label = "gl-mt300a:lan";
  18. gpios = <&gpio2 1 1>;
  19. };
  20. wlan {
  21. label = "gl-mt300a:wlan";
  22. gpios = <&gpio3 0 1>;
  23. };
  24. usb {
  25. label = "gl-mt300a:usb";
  26. gpios = <&gpio0 7 1>;
  27. };
  28. };
  29. gpio-keys-polled {
  30. compatible = "gpio-keys-polled";
  31. #address-cells = <1>;
  32. #size-cells = <0>;
  33. poll-interval = <20>;
  34. reset {
  35. label = "reset";
  36. gpios = <&gpio0 13 1>;
  37. linux,code = <KEY_RESTART>;
  38. };
  39. BTN_0 {
  40. label = "BTN_0";
  41. gpios = <&gpio0 1 1>;
  42. linux,code = <BTN_0>;
  43. };
  44. BTN_1 {
  45. label = "BTN_1";
  46. gpios = <&gpio0 2 1>;
  47. linux,code = <BTN_1>;
  48. };
  49. };
  50. };
  51. &gpio0 {
  52. status = "okay";
  53. };
  54. &gpio1 {
  55. status = "okay";
  56. };
  57. &gpio2 {
  58. status = "okay";
  59. };
  60. &gpio3 {
  61. status = "okay";
  62. };
  63. &spi0 {
  64. status = "okay";
  65. m25p80@0 {
  66. #address-cells = <1>;
  67. #size-cells = <1>;
  68. compatible = "jedec,spi-nor";
  69. reg = <0>;
  70. spi-max-frequency = <10000000>;
  71. partition@0 {
  72. label = "u-boot";
  73. reg = <0x0 0x30000>;
  74. };
  75. partition@30000 {
  76. label = "u-boot-env";
  77. reg = <0x30000 0x10000>;
  78. read-only;
  79. };
  80. factory: partition@40000 {
  81. label = "factory";
  82. reg = <0x40000 0x10000>;
  83. read-only;
  84. };
  85. partition@50000 {
  86. label = "firmware";
  87. reg = <0x50000 0xf80000>;
  88. };
  89. partition@ff0000 {
  90. label = "art";
  91. reg = <0xff0000 0x10000>;
  92. };
  93. };
  94. };
  95. &sdhci {
  96. status = "okay";
  97. };
  98. &ehci {
  99. status = "okay";
  100. };
  101. &ohci {
  102. status = "okay";
  103. };
  104. &ethernet {
  105. pinctrl-names = "default";
  106. pinctrl-0 = <&ephy_pins>;
  107. mtd-mac-address = <&factory 0x4000>;
  108. ralink,port-map = "wllll";
  109. };
  110. &wmac {
  111. ralink,mtd-eeprom = <&factory 0>;
  112. };
  113. &pinctrl {
  114. state_default: pinctrl0 {
  115. gpio {
  116. ralink,group = "wled","ephy","uartf","i2c";
  117. ralink,function = "gpio";
  118. };
  119. };
  120. };