83c9fc8645fabfefb13ba1b9ec9d93fbe651f247
[openwrt/staging/mkresin.git] / target / linux / ramips / dts / mt7620n_dlink_dwr-922-e2.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7620n.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "dlink,dwr-922-e2", "ralink,mt7620n-soc";
10 model = "D-Link DWR-922 E2";
11
12 aliases {
13 led-boot = &sstrengthg;
14 led-failsafe = &sstrengthg;
15 };
16
17 keys {
18 compatible = "gpio-keys";
19
20 wps {
21 label = "wps";
22 gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
23 linux,code = <KEY_WPS_BUTTON>;
24 };
25
26 reset {
27 label = "reset";
28 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
29 linux,code = <KEY_RESTART>;
30 };
31 };
32
33 leds {
34 compatible = "gpio-leds";
35 led-boot = &sstrengthg;
36
37 sms {
38 label = "dwr-922-e2:green:sms";
39 gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
40 };
41
42 lan {
43 label = "dwr-922-e2:green:lan";
44 gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
45 };
46
47 sstrengthg: sstrengthg {
48 label = "dwr-922-e2:green:sigstrength";
49 gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
50 };
51
52 sstrengthr {
53 label = "dwr-922-e2:red:sigstrength";
54 gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
55 };
56
57 4g {
58 label = "dwr-922-e2:green:4g";
59 gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
60 };
61
62 3g {
63 label = "dwr-922-e2:green:3g";
64 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
65 };
66
67 wifi {
68 label = "dwr-922-e2:green:wifi";
69 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
70 };
71 };
72
73 gpio_export {
74 compatible = "gpio-export";
75 #size-cells = <0>;
76
77 lte_modem_enable {
78 gpio-export,name = "lte_modem_enable";
79 gpio-export,output = <1>;
80 gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
81 };
82 };
83 };
84
85 &gpio1 {
86 status = "okay";
87 };
88
89 &gpio2 {
90 status = "okay";
91 };
92
93 &gpio3 {
94 status = "okay";
95 };
96
97 &spi0 {
98 status = "okay";
99
100 flash@0 {
101 compatible = "jedec,spi-nor";
102 reg = <0>;
103 spi-max-frequency = <10000000>;
104
105 partitions {
106 compatible = "fixed-partitions";
107 #address-cells = <1>;
108 #size-cells = <1>;
109
110 partition@0 {
111 label = "jboot";
112 reg = <0x0 0x10000>;
113 read-only;
114 };
115
116 partition@10000 {
117 compatible = "amit,jimage";
118 label = "firmware";
119 reg = <0x10000 0xfe0000>;
120 };
121
122 config: partition@ff0000 {
123 label = "config";
124 reg = <0xff0000 0x10000>;
125 read-only;
126 };
127 };
128 };
129 };
130
131 &ehci {
132 status = "okay";
133 };
134
135 &ohci {
136 status = "okay";
137 };
138
139 &ethernet {
140 port@4 {
141 status = "okay";
142 };
143 };
144
145 &state_default {
146 default {
147 groups = "spi refclk", "i2c", "ephy", "wled";
148 function = "gpio";
149 };
150 };