ramips: use phy trigger for various Netgear boards
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_netgear_r6350.dts
1 // SPDX-License-Identifier: GPL-2.0
2 /dts-v1/;
3
4 #include "mt7621.dtsi"
5
6 #include <dt-bindings/gpio/gpio.h>
7 #include <dt-bindings/input/input.h>
8
9 / {
10 compatible = "netgear,r6350", "mediatek,mt7621-soc";
11 model = "Netgear R6350";
12
13 aliases {
14 led-boot = &led_power;
15 led-failsafe = &led_power;
16 led-running = &led_power;
17 led-upgrade = &led_power;
18 };
19
20 chosen {
21 bootargs = "console=ttyS0,57600";
22 };
23
24 leds {
25 compatible = "gpio-leds";
26
27 led_power: power {
28 label = "r6350:green:power";
29 gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
30 };
31
32 usb {
33 label = "r6350:green:usb";
34 gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
35 trigger-sources = <&xhci_ehci_port1>, <&ehci_port2>;
36 linux,default-trigger = "usbport";
37 };
38
39 internet {
40 label = "r6350:green:wan";
41 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
42 };
43
44 wifi {
45 label = "r6350:green:wifi";
46 gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
47 linux,default-trigger = "phy0tpt";
48 };
49 };
50
51 keys {
52 compatible = "gpio-keys-polled";
53 poll-interval = <20>;
54
55 wps {
56 label = "wps";
57 gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
58 linux,code = <KEY_WPS_BUTTON>;
59 };
60
61 reset {
62 label = "reset";
63 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
64 linux,code = <KEY_RESTART>;
65 };
66 };
67
68 gpio_export {
69 compatible = "gpio-export";
70 #size-cells = <0>;
71
72 usbpower {
73 gpio-export,name = "usbpower";
74 gpio-export,output = <1>;
75 gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
76 };
77 };
78 };
79
80 &nand {
81 status = "okay";
82
83 partitions {
84 compatible = "fixed-partitions";
85 #address-cells = <1>;
86 #size-cells = <1>;
87
88 partition@0 {
89 label = "u-boot";
90 reg = <0x0 0x100000>;
91 read-only;
92 };
93
94 partition@100000 {
95 label = "SC PART_MAP";
96 reg = <0x100000 0x100000>;
97 read-only;
98 };
99
100 partition@200000 {
101 label = "kernel";
102 reg = <0x200000 0x400000>;
103 };
104
105 partition@600000 {
106 label = "ubi";
107 reg = <0x600000 0x2800000>;
108 };
109
110 partition@2e00000 {
111 label = "reserved0";
112 reg = <0x2e00000 0x1800000>;
113 read-only;
114 };
115
116 factory: partition@4600000 {
117 label = "factory";
118 reg = <0x4600000 0x200000>;
119 read-only;
120 };
121
122 partition@4800000 {
123 label = "reserved1";
124 reg = <0x4800000 0x3800000>;
125 read-only;
126 };
127 };
128 };
129
130 &pcie {
131 status = "okay";
132 };
133
134 &pcie1 {
135 wifi@0,0 {
136 reg = <0x0 0 0 0 0>;
137 mediatek,mtd-eeprom = <&factory 0x0>;
138 ieee80211-freq-limit = <2400000 2500000>;
139 };
140 };
141
142 &ethernet {
143 mtd-mac-address = <&factory 0x4>;
144 };
145
146 &pinctrl {
147 state_default: pinctrl0 {
148 gpio {
149 ralink,group = "uart3", "uart2", "jtag", "wdt";
150 ralink,function = "gpio";
151 };
152 };
153 };