mt7981a-ubnt-unifi-6-plus.dts 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
  2. /dts-v1/;
  3. #include "mt7981.dtsi"
  4. / {
  5. model = "Ubiquiti UniFi 6 Plus";
  6. compatible = "ubnt,unifi-6-plus", "mediatek,mt7981";
  7. aliases {
  8. serial0 = &uart0;
  9. led-boot = &led_white;
  10. led-failsafe = &led_white;
  11. led-running = &led_blue;
  12. led-upgrade = &led_blue;
  13. label-mac-device = &gmac1;
  14. };
  15. chosen {
  16. bootargs-override = "console=ttyS0,115200n8 rootwait root=/dev/mmcblk0p7";
  17. stdout-path = "serial0:115200n8";
  18. };
  19. gpio-keys {
  20. compatible = "gpio-keys";
  21. reset {
  22. label = "reset";
  23. linux,code = <KEY_RESTART>;
  24. gpios = <&pio 1 GPIO_ACTIVE_LOW>;
  25. };
  26. };
  27. leds {
  28. compatible = "gpio-leds";
  29. led_blue: dome-blue {
  30. label = "blue:dome";
  31. gpios = <&pio 9 GPIO_ACTIVE_HIGH>;
  32. };
  33. led_white: dome-white {
  34. label = "white:dome";
  35. gpios = <&pio 34 GPIO_ACTIVE_HIGH>;
  36. };
  37. };
  38. };
  39. &uart0 {
  40. status = "okay";
  41. };
  42. &watchdog {
  43. status = "okay";
  44. };
  45. &pio {
  46. spi2_flash_pins: spi2-pins {
  47. mux {
  48. function = "spi";
  49. groups = "spi2", "spi2_wp_hold";
  50. };
  51. conf-pu {
  52. pins = "SPI2_CS", "SPI2_HOLD", "SPI2_WP";
  53. drive-strength = <8>;
  54. bias-pull-up = <103>;
  55. };
  56. conf-pd {
  57. pins = "SPI2_CLK", "SPI2_MOSI", "SPI2_MISO";
  58. drive-strength = <8>;
  59. bias-pull-down = <103>;
  60. };
  61. };
  62. mmc0_pins_default: mmc0-pins-default {
  63. mux {
  64. function = "flash";
  65. groups = "emmc_45";
  66. };
  67. };
  68. mmc0_pins_uhs: mmc0-pins-uhs {
  69. mux {
  70. function = "flash";
  71. groups = "emmc_45";
  72. };
  73. };
  74. };
  75. &spi2 {
  76. pinctrl-names = "default";
  77. pinctrl-0 = <&spi2_flash_pins>;
  78. status = "okay";
  79. flash@0 {
  80. #address-cells = <1>;
  81. #size-cells = <1>;
  82. compatible = "jedec,spi-nor";
  83. reg = <0>;
  84. spi-max-frequency = <52000000>;
  85. spi-tx-bus-width = <4>;
  86. spi-rx-bus-width = <4>;
  87. partitions {
  88. compatible = "fixed-partitions";
  89. #address-cells = <1>;
  90. #size-cells = <1>;
  91. eeprom: partition@00000 {
  92. label = "EEPROM";
  93. reg = <0x00000 0x10000>;
  94. read-only;
  95. nvmem-layout {
  96. compatible = "fixed-layout";
  97. #address-cells = <1>;
  98. #size-cells = <1>;
  99. macaddr_eeprom_0: macaddr@0 {
  100. reg = <0x0 0x6>;
  101. };
  102. macaddr_eeprom_6: macaddr@6 {
  103. reg = <0x6 0x6>;
  104. };
  105. };
  106. };
  107. partition@10000 {
  108. label = "u-boot-env";
  109. reg = <0x10000 0x80000>;
  110. };
  111. };
  112. };
  113. };
  114. &mmc0 {
  115. pinctrl-names = "default", "state_uhs";
  116. pinctrl-0 = <&mmc0_pins_default>;
  117. pinctrl-1 = <&mmc0_pins_uhs>;
  118. bus-width = <8>;
  119. max-frequency = <52000000>;
  120. cap-mmc-highspeed;
  121. vmmc-supply = <&reg_3p3v>;
  122. non-removable;
  123. status = "okay";
  124. };
  125. &eth {
  126. pinctrl-names = "default";
  127. pinctrl-0 = <&mdio_pins>;
  128. status = "okay";
  129. gmac1: mac@1 {
  130. compatible = "mediatek,eth-mac";
  131. reg = <1>;
  132. phy-mode = "gmii";
  133. phy-handle = <&int_gbe_phy>;
  134. nvmem-cell-names = "mac-address";
  135. nvmem-cells = <&macaddr_eeprom_0>;
  136. };
  137. };
  138. &wifi {
  139. status = "okay";
  140. };