1
0

kng_rc.dts 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. /dts-v1/;
  2. #include "mt7620a.dtsi"
  3. #include <dt-bindings/gpio/gpio.h>
  4. #include <dt-bindings/input/input.h>
  5. / {
  6. model = "ZyXEL Keenetic Viva";
  7. gpio-leds {
  8. compatible = "gpio-leds";
  9. wan {
  10. label = "kng_rc:green:wan";
  11. gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
  12. };
  13. usb {
  14. label = "kng_rc:green:usb";
  15. gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
  16. };
  17. power_alert {
  18. label = "kng_rc:red:power";
  19. gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
  20. };
  21. wifi {
  22. label = "kng_rc:green:wifi";
  23. gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
  24. };
  25. power {
  26. label = "kng_rc:green:power";
  27. gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
  28. };
  29. };
  30. gpio-keys-polled {
  31. compatible = "gpio-keys";
  32. #address-cells = <1>;
  33. #size-cells = <0>;
  34. poll-interval = <20>;
  35. reset {
  36. label = "reset";
  37. gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
  38. linux,code = <KEY_RESTART>;
  39. };
  40. wps {
  41. label = "wps";
  42. gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
  43. linux,code = <KEY_WPS_BUTTON>;
  44. };
  45. fn {
  46. label = "fn";
  47. gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
  48. linux,code = <BTN_0>;
  49. };
  50. };
  51. rtl8367rb {
  52. compatible = "realtek,rtl8367b";
  53. cpu_port = <7>;
  54. realtek,extif2 = <1 0 1 1 1 1 1 1 2>;
  55. mdio = <&mdio0>;
  56. };
  57. };
  58. &spi0 {
  59. status = "okay";
  60. m25p80@0 {
  61. #address-cells = <1>;
  62. #size-cells = <1>;
  63. compatible = "jedec,spi-nor";
  64. reg = <0>;
  65. spi-max-frequency = <10000000>;
  66. partition@0 {
  67. label = "u-boot";
  68. reg = <0x0 0x30000>;
  69. read-only;
  70. };
  71. partition@30000 {
  72. label = "u-boot-env";
  73. reg = <0x30000 0x10000>;
  74. read-only;
  75. };
  76. factory: partition@40000 {
  77. label = "factory";
  78. reg = <0x40000 0x10000>;
  79. read-only;
  80. };
  81. partition@50000 {
  82. label = "firmware";
  83. reg = <0x50000 0xfb0000>;
  84. };
  85. };
  86. };
  87. &pinctrl {
  88. state_default: pinctrl0 {
  89. gpio {
  90. ralink,group = "i2c", "uartf";
  91. ralink,function = "gpio";
  92. };
  93. };
  94. };
  95. &ethernet {
  96. status = "okay";
  97. pinctrl-names = "default";
  98. pinctrl-0 = <&rgmii2_pins &mdio_pins>;
  99. mtd-mac-address = <&factory 0x00004>;
  100. port@4 {
  101. status = "okay";
  102. mediatek,fixed-link = <1000 1 1 1>;
  103. phy-mode = "rgmii";
  104. phy-handle = <&phy4>;
  105. };
  106. mdio0: mdio-bus {
  107. status = "okay";
  108. phy4: ethernet-phy@4 {
  109. reg = <4>;
  110. phy-mode = "rgmii";
  111. };
  112. };
  113. };
  114. &gsw {
  115. mediatek,port4 = "gmac";
  116. };
  117. &wmac {
  118. ralink,mtd-eeprom = <&factory 0>;
  119. };
  120. &ehci {
  121. status = "okay";
  122. };
  123. &ohci {
  124. status = "okay";
  125. };