mt7620n_kingston_mlw221.dts 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. #include "mt7620n.dtsi"
  2. #include <dt-bindings/gpio/gpio.h>
  3. #include <dt-bindings/input/input.h>
  4. / {
  5. compatible = "kingston,mlw221", "ralink,mt7620n-soc";
  6. model = "Kingston MLW221";
  7. aliases {
  8. led-boot = &led_system;
  9. led-failsafe = &led_system;
  10. led-running = &led_system;
  11. led-upgrade = &led_system;
  12. };
  13. leds {
  14. compatible = "gpio-leds";
  15. led_system: system {
  16. label = "blue:system";
  17. gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
  18. };
  19. wifi {
  20. label = "blue:wifi";
  21. gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
  22. };
  23. };
  24. keys {
  25. compatible = "gpio-keys";
  26. reset {
  27. label = "reset";
  28. gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
  29. linux,code = <KEY_RESTART>;
  30. };
  31. system {
  32. label = "system";
  33. gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
  34. linux,code = <KEY_RFKILL>;
  35. };
  36. };
  37. };
  38. &gpio0 {
  39. status = "okay";
  40. };
  41. &gpio2 {
  42. status = "okay";
  43. };
  44. &gpio3 {
  45. status = "okay";
  46. };
  47. &spi0 {
  48. status = "okay";
  49. flash@0 {
  50. compatible = "jedec,spi-nor";
  51. reg = <0>;
  52. spi-max-frequency = <10000000>;
  53. partitions {
  54. compatible = "fixed-partitions";
  55. #address-cells = <1>;
  56. #size-cells = <1>;
  57. partition@0 {
  58. label = "u-boot";
  59. reg = <0x0 0x30000>;
  60. read-only;
  61. };
  62. partition@30000 {
  63. label = "u-boot-env";
  64. reg = <0x30000 0x10000>;
  65. read-only;
  66. };
  67. factory: partition@40000 {
  68. label = "factory";
  69. reg = <0x40000 0x10000>;
  70. read-only;
  71. };
  72. partition@50000 {
  73. compatible = "denx,uimage";
  74. label = "firmware";
  75. reg = <0x50000 0xf60000>;
  76. };
  77. partition@fb0000 {
  78. label = "user-config";
  79. reg = <0xfb0000 0x50000>;
  80. };
  81. };
  82. };
  83. };
  84. &ehci {
  85. status = "okay";
  86. };
  87. &ohci {
  88. status = "okay";
  89. };
  90. &ethernet {
  91. mtd-mac-address = <&factory 0x4>;
  92. mediatek,portmap = "wllll";
  93. };
  94. &wmac {
  95. ralink,mtd-eeprom = <&factory 0x0>;
  96. };
  97. &state_default {
  98. default {
  99. groups = "i2c", "ephy", "wled";
  100. function = "gpio";
  101. };
  102. };