1 // SPDX-License-Identifier: (GPL-2.0 OR MIT)
3 * Copyright (C) 2022 SmartRG Inc.
4 * Author: Chad Monroe <chad.monroe@smartrg.com>
8 #include <dt-bindings/input/input.h>
9 #include <dt-bindings/gpio/gpio.h>
10 #include <dt-bindings/leds/common.h>
12 #include "mt7986a.dtsi"
19 led-boot = &led_status_green;
20 led-failsafe = &led_status_red;
21 led-running = &led_status_white;
22 led-upgrade = &led_status_blue;
26 stdout-path = "serial0:115200n8";
27 bootargs = "root=/dev/mmcblk0p5";
31 device_type = "memory";
32 reg = <0 0x40000000 0 0x40000000>;
40 /delete-node/ramoops@42ff0000;
42 bootdata_reserved: bootdata@45000000 {
44 reg = <0x0 0x45000000 0x0 0x00001000>;
47 ramoops_reserved: ramoops@45001000 {
49 compatible = "ramoops";
50 reg = <0x0 0x45001000 0x0 0x00140000>;
51 ftrace-size = <0x20000>;
52 record-size = <0x20000>;
53 console-size = <0x20000>;
54 pmsg-size = <0x80000>;
59 compatible = "bootdata";
60 memory-region = <&bootdata_reserved>;
63 reg_1p8v: regulator-1p8v {
64 compatible = "regulator-fixed";
65 regulator-name = "fixed-1.8V";
66 regulator-min-microvolt = <1800000>;
67 regulator-max-microvolt = <1800000>;
72 reg_3p3v: regulator-3p3v {
73 compatible = "regulator-fixed";
74 regulator-name = "fixed-3.3V";
75 regulator-min-microvolt = <3300000>;
76 regulator-max-microvolt = <3300000>;
81 reg_5v: regulator-5v {
82 compatible = "regulator-fixed";
83 regulator-name = "fixed-5V";
84 regulator-min-microvolt = <5000000>;
85 regulator-max-microvolt = <5000000>;
91 compatible = "pwm-fan";
93 pwms = <&pwm 1 40000 0>;
99 * 51 = 20% duty cycle (minimum supported)
100 * 61 = 24% duty cycle (2020 RPM)
101 * 77 = 30% duty cycle (3000 RPM)
102 * 102 = 40% duty cycle (3600 RPM)
103 * 255 = 100% duty cycle
105 cooling-levels = <51 61 77 102>;
107 interrupt-parent = <&pio>;
108 interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
109 pulses-per-revolution = <2>;
115 compatible = "gpio-keys";
116 pinctrl-names = "default";
117 pinctrl-0 = <&button_pins>;
121 linux,code = <KEY_RESTART>;
122 gpios = <&pio 17 GPIO_ACTIVE_LOW>;
130 /* active: set fan to cooling level 3 */
131 cooling-device = <&fan 3 3>;
132 trip = <&cpu_trip_active_high>;
136 /* active: set fan to cooling level 2 */
137 cooling-device = <&fan 2 2>;
138 trip = <&cpu_trip_active_medium>;
142 /* active: set fan to cooling level 1 */
143 cooling-device = <&fan 1 1>;
144 trip = <&cpu_trip_active_low>;
148 /* active: set fan to cooling level 0 */
149 cooling-device = <&fan 0 0>;
150 trip = <&cpu_trip_active_silent>;
155 cpu_trip_active_high: active-high {
156 temperature = <110000>;
161 cpu_trip_active_medium: active-medium {
162 temperature = <80000>;
167 cpu_trip_active_low: active-low {
168 temperature = <60000>;
173 cpu_trip_active_silent: active-silent {
174 temperature = <40000>;
189 compatible = "mediatek,eth-mac";
192 phy-mode = "2500base-x";
198 compatible = "mediatek,eth-mac";
201 phy-mode = "2500base-x";
205 #address-cells = <1>;
211 #address-cells = <1>;
214 reset-gpios = <&pio 6 GPIO_ACTIVE_LOW>;
215 reset-delay-us = <1500000>;
216 reset-post-delay-us = <1000000>;
218 phy5: ethernet-phy@5 {
220 compatible = "maxlinear,gpy211", "ethernet-phy-ieee802.3-c45";
224 mxl,led-config = <0x30 0x40 0x80 0x0>;
227 phy6: ethernet-phy@6 {
229 compatible = "maxlinear,gpy211", "ethernet-phy-ieee802.3-c45";
233 mxl,led-config = <0x30 0x40 0x80 0x0>;
242 pinctrl-names = "default", "state_uhs";
243 pinctrl-0 = <&mmc0_pins_default>;
244 pinctrl-1 = <&mmc0_pins_uhs>;
246 max-frequency = <200000000>;
250 hs400-ds-delay = <0x14014>;
251 vmmc-supply = <®_3p3v>;
252 vqmmc-supply = <®_1p8v>;
260 pinctrl-names = "default";
261 pinctrl-0 = <&pcie_pins>;
265 reg = <0x0000 0 0 0 0>;
268 reg = <0x0000 0 0 0 0>;
279 pinctrl-names = "default";
280 pinctrl-0 = <&wf_2g_5g_pins>;
284 mmc0_pins_default: mmc0-pins {
290 pins = "EMMC_DATA_0", "EMMC_DATA_1", "EMMC_DATA_2",
291 "EMMC_DATA_3", "EMMC_DATA_4", "EMMC_DATA_5",
292 "EMMC_DATA_6", "EMMC_DATA_7", "EMMC_CMD";
294 drive-strength = <4>;
295 mediatek,pull-up-adv = <1>; /* pull-up 10K */
299 drive-strength = <6>;
300 mediatek,pull-down-adv = <2>; /* pull-down 50K */
304 mediatek,pull-down-adv = <2>; /* pull-down 50K */
308 drive-strength = <4>;
309 mediatek,pull-up-adv = <1>; /* pull-up 10K */
313 mmc0_pins_uhs: mmc0-uhs-pins {
319 pins = "EMMC_DATA_0", "EMMC_DATA_1", "EMMC_DATA_2",
320 "EMMC_DATA_3", "EMMC_DATA_4", "EMMC_DATA_5",
321 "EMMC_DATA_6", "EMMC_DATA_7", "EMMC_CMD";
323 drive-strength = <4>;
324 mediatek,pull-up-adv = <1>; /* pull-up 10K */
328 drive-strength = <6>;
329 mediatek,pull-down-adv = <2>; /* pull-down 50K */
333 mediatek,pull-down-adv = <2>; /* pull-down 50K */
337 drive-strength = <4>;
338 mediatek,pull-up-adv = <1>; /* pull-up 10K */
342 pcie_pins: pcie-pins {
345 groups = "pcie_clk", "pcie_pereset";
349 button_pins: button-pins {
351 mediatek,pull-down-adv = <0>; /* bias-disable */
354 uart1_pins: uart1-pins {
357 groups = "uart1_2_rx_tx", "uart1_2_cts_rts";
361 i2c0_pins: i2c0-pins {
371 groups = "pwm0", "pwm1_0";
375 wf_2g_5g_pins: wf-2g-5g-pins {
378 groups = "wf_2g", "wf_5g";
381 pins = "WF0_HB1", "WF0_HB2", "WF0_HB3", "WF0_HB4",
382 "WF0_HB0", "WF0_HB0_B", "WF0_HB5", "WF0_HB6",
383 "WF0_HB7", "WF0_HB8", "WF0_HB9", "WF0_HB10",
384 "WF0_TOP_CLK", "WF0_TOP_DATA", "WF1_HB1",
385 "WF1_HB2", "WF1_HB3", "WF1_HB4", "WF1_HB0",
386 "WF1_HB5", "WF1_HB6", "WF1_HB7", "WF1_HB8",
387 "WF1_TOP_CLK", "WF1_TOP_DATA";
388 drive-strength = <4>;
392 mux_sel: mux-sel-hog {
394 gpios = <23 GPIO_ACTIVE_LOW>;
395 line-name = "mux-sel";
401 gpios = <24 GPIO_ACTIVE_LOW>;
402 line-name = "mux-oe";
408 vusb33-supply = <®_3p3v>;
409 vbus-supply = <®_5v>;
422 pinctrl-names = "default";
423 pinctrl-0 = <&uart1_pins>;
426 /* DA14531MOD Bluetooth */
428 compatible = "renesas,DA14531";
429 reset-gpios = <&pio 27 GPIO_ACTIVE_LOW>;
438 pinctrl-names = "default";
439 pinctrl-0 = <&i2c0_pins>;
443 compatible = "srg,sysled";
446 led_status_red: led@1 {
447 color = <LED_COLOR_ID_RED>;
448 function = LED_FUNCTION_STATUS;
452 led_status_green: led@2 {
453 color = <LED_COLOR_ID_GREEN>;
454 function = LED_FUNCTION_STATUS;
458 led_status_blue: led@3 {
459 color = <LED_COLOR_ID_BLUE>;
460 function = LED_FUNCTION_STATUS;
464 led_status_white: led@4 {
465 color = <LED_COLOR_ID_WHITE>;
466 function = LED_FUNCTION_STATUS;
473 pinctrl-names = "default";
474 pinctrl-0 = <&pwm_pins>;
479 interrupts = <GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;