1
0

GL-MT300A.dts 2.1 KB

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