DIR-645.dts 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. /dts-v1/;
  2. #include "rt3883.dtsi"
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/input/input.h>
  5. / {
  6. compatible = "dlink,dir-645", "ralink,rt3883-soc";
  7. model = "D-Link DIR-645";
  8. aliases {
  9. led-boot = &led_wps;
  10. led-failsafe = &led_wps;
  11. led-running = &led_wps;
  12. led-upgrade = &led_wps;
  13. };
  14. rtl8367b {
  15. compatible = "realtek,rtl8367b";
  16. gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
  17. gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
  18. realtek,extif1 = <1 0 1 1 1 1 1 1 2>;
  19. };
  20. keys {
  21. compatible = "gpio-keys-polled";
  22. poll-interval = <100>;
  23. reset {
  24. label = "reset";
  25. gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
  26. linux,code = <KEY_RESTART>;
  27. };
  28. wps {
  29. label = "wps";
  30. gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
  31. linux,code = <KEY_WPS_BUTTON>;
  32. };
  33. };
  34. leds {
  35. compatible = "gpio-leds";
  36. inet {
  37. label = "dir-645:green:inet";
  38. gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
  39. };
  40. led_wps: wps {
  41. label = "dir-645:green:wps";
  42. gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
  43. };
  44. };
  45. gpio_export {
  46. compatible = "gpio-export";
  47. #size-cells = <0>;
  48. usb {
  49. gpio-export,name = "usb";
  50. gpio-export,output = <1>;
  51. gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
  52. };
  53. };
  54. };
  55. &gpio1 {
  56. status = "okay";
  57. };
  58. &spi0 {
  59. status = "okay";
  60. m25p80@0 {
  61. compatible = "jedec,spi-nor";
  62. reg = <0>;
  63. spi-max-frequency = <25000000>;
  64. partitions {
  65. compatible = "fixed-partitions";
  66. #address-cells = <1>;
  67. #size-cells = <1>;
  68. partition@0 {
  69. label = "uboot";
  70. reg = <0x0 0x30000>;
  71. read-only;
  72. };
  73. partition@30000 {
  74. label = "uboot-env";
  75. reg = <0x30000 0x4000>;
  76. read-only;
  77. };
  78. factory: partition@34000 {
  79. label = "factory";
  80. reg = <0x34000 0x4000>;
  81. read-only;
  82. };
  83. partition@38000 {
  84. label = "nvram";
  85. reg = <0x38000 0x8000>;
  86. read-only;
  87. };
  88. partition@40000 {
  89. label = "devdata";
  90. reg = <0x40000 0x10000>;
  91. };
  92. partition@50000 {
  93. compatible = "seama";
  94. label = "firmware";
  95. reg = <0x50000 0x7b0000>;
  96. };
  97. };
  98. };
  99. };
  100. &pinctrl {
  101. state_default: pinctrl0 {
  102. gpio {
  103. ralink,group = "i2c", "jtag", "uartf";
  104. ralink,function = "gpio";
  105. };
  106. };
  107. };
  108. &ethernet {
  109. mtd-mac-address = <&factory 0x4>;
  110. port@0 {
  111. mediatek,fixed-link = <1000 1 1 0>;
  112. };
  113. };
  114. &wmac {
  115. ralink,5ghz = <0>;
  116. ralink,mtd-eeprom = <&factory 0>;
  117. };
  118. &ehci {
  119. status = "okay";
  120. };
  121. &ohci {
  122. status = "okay";
  123. };