1
0

CF-WR800N.dts 1.8 KB

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