MLW221.dts 1.8 KB

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