ar9331_tl_mr3020.dts 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. // SPDX-License-Identifier: GPL-2.0
  2. /dts-v1/;
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/input/input.h>
  5. #include "ar9331.dtsi"
  6. / {
  7. model = "TP-Link TL-MR3020";
  8. compatible = "tplink,tl-mr3020";
  9. aliases {
  10. serial0 = &uart;
  11. };
  12. memory@0 {
  13. device_type = "memory";
  14. reg = <0x0 0x2000000>;
  15. };
  16. leds {
  17. compatible = "gpio-leds";
  18. wlan {
  19. label = "tp-link:green:wlan";
  20. gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
  21. default-state = "off";
  22. };
  23. lan {
  24. label = "tp-link:green:lan";
  25. gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
  26. default-state = "off";
  27. };
  28. wps {
  29. label = "tp-link:green:wps";
  30. gpios = <&gpio 26 GPIO_ACTIVE_LOW>;
  31. default-state = "off";
  32. };
  33. led3g {
  34. label = "tp-link:green:3g";
  35. gpios = <&gpio 27 GPIO_ACTIVE_LOW>;
  36. default-state = "off";
  37. };
  38. };
  39. gpio-keys {
  40. compatible = "gpio-keys";
  41. #address-cells = <1>;
  42. #size-cells = <0>;
  43. button@0 {
  44. label = "wps";
  45. linux,code = <KEY_WPS_BUTTON>;
  46. gpios = <&gpio 11 GPIO_ACTIVE_HIGH>;
  47. };
  48. button@1 {
  49. label = "sw1";
  50. linux,code = <BTN_0>;
  51. gpios = <&gpio 18 GPIO_ACTIVE_HIGH>;
  52. };
  53. button@2 {
  54. label = "sw2";
  55. linux,code = <BTN_1>;
  56. gpios = <&gpio 20 GPIO_ACTIVE_HIGH>;
  57. };
  58. };
  59. reg_usb_vbus: reg_usb_vbus {
  60. compatible = "regulator-fixed";
  61. regulator-name = "usb_vbus";
  62. regulator-min-microvolt = <5000000>;
  63. regulator-max-microvolt = <5000000>;
  64. gpio = <&gpio 8 GPIO_ACTIVE_HIGH>;
  65. enable-active-high;
  66. };
  67. };
  68. &ref {
  69. clock-frequency = <25000000>;
  70. };
  71. &uart {
  72. status = "okay";
  73. };
  74. &gpio {
  75. status = "okay";
  76. };
  77. &usb {
  78. dr_mode = "host";
  79. vbus-supply = <&reg_usb_vbus>;
  80. status = "okay";
  81. };
  82. &usb_phy {
  83. status = "okay";
  84. };
  85. &spi {
  86. num-chipselects = <1>;
  87. status = "okay";
  88. /* Spansion S25FL032PIF SPI flash */
  89. spiflash: s25sl032p@0 {
  90. #address-cells = <1>;
  91. #size-cells = <1>;
  92. compatible = "spansion,s25sl032p", "jedec,spi-nor";
  93. spi-max-frequency = <104000000>;
  94. reg = <0>;
  95. };
  96. };