6cb693b2e212e472cb5e080a152378b33c5f9edb
[openwrt/staging/mkresin.git] / target / linux / lantiq / files-5.4 / arch / mips / boot / dts / lantiq / ar9_avm_fritz7312.dts
1 #include "ar9.dtsi"
2
3 #include <dt-bindings/input/input.h>
4
5 / {
6 compatible = "avm,fritz7312", "lantiq,xway", "lantiq,ar9";
7 model = "AVM FRITZ!Box 7312";
8
9 chosen {
10 bootargs = "console=ttyLTQ0,115200";
11 };
12
13 aliases {
14 led-boot = &power;
15 led-failsafe = &power;
16 led-running = &power;
17 led-upgrade = &power;
18
19 led-dsl = &info_green;
20 led-wifi = &wlan;
21 };
22
23 memory@0 {
24 device_type = "memory";
25 reg = <0x0 0x4000000>;
26 };
27
28 keys {
29 compatible = "gpio-keys-polled";
30 poll-interval = <100>;
31
32 wlan {
33 label = "wlan";
34 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
35 linux,code = <KEY_RFKILL>;
36 };
37 dect {
38 label = "dect";
39 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
40 linux,code = <KEY_PHONE>;
41 };
42 };
43
44 leds {
45 compatible = "gpio-leds";
46
47 power: power {
48 label = "fritz7312:green:power";
49 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
50 default-state = "keep";
51 };
52 voice {
53 label = "fritz7312:green:fon";
54 gpios = <&gpio 47 GPIO_ACTIVE_LOW>;
55 };
56 dect {
57 label = "fritz7312:green:dect";
58 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
59 };
60 wlan: wlan {
61 label = "fritz7312:green:wlan";
62 gpios = <&gpio 37 GPIO_ACTIVE_LOW>;
63 };
64 info_green: info_green {
65 label = "fritz7312:green:info";
66 gpios = <&gpio 35 GPIO_ACTIVE_LOW>;
67 };
68 };
69 };
70
71 &gpio {
72 pinctrl-names = "default";
73 pinctrl-0 = <&state_default>;
74
75 state_default: pinmux {
76 ar8030-intr {
77 lantiq,groups = "exin3";
78 lantiq,function = "exin";
79 lantiq,pull = <2>;
80 lantiq,output = <0>;
81 };
82 ar8030-clk {
83 lantiq,groups = "clkout2";
84 lantiq,output = <1>;
85 lantiq,open-drain;
86 };
87 ar8030-rst {
88 lantiq,pins = "io34";
89 lantiq,output = <1>;
90 lantiq,pull = <2>;
91 lantiq,open-drain;
92 };
93 };
94 };
95
96 &gsw {
97 phy-mode = "rmii";
98 phy-handle = <&phy0>;
99 mtd-mac-address = <&ath9k_cal 0xa91>;
100 mtd-mac-address-increment = <(-2)>;
101
102 mdio-bus {
103 #address-cells = <1>;
104 #size-cells = <0>;
105
106 phy0: ethernet-phy@0 {
107 reg = <0>;
108 reset-gpios = <&gpio 34 GPIO_ACTIVE_LOW>;
109 max-speed = <100>;
110 };
111 };
112 };
113
114 &localbus {
115 flash@0 {
116 compatible = "lantiq,nor";
117 bank-width = <2>;
118 reg = <0 0x0 0x1000000>;
119
120 partitions {
121 compatible = "fixed-partitions";
122 #address-cells = <1>;
123 #size-cells = <1>;
124
125 ath9k_cal: partition@0 {
126 label = "urlader";
127 reg = <0x00000 0x20000>;
128 read-only;
129 };
130
131 partition@20000 {
132 label = "firmware";
133 reg = <0x20000 0xf60000>;
134 };
135
136 partition@f80000 {
137 label = "tffs (1)";
138 reg = <0xf80000 0x40000>;
139 read-only;
140 };
141
142 partition@fc0000 {
143 label = "tffs (2)";
144 reg = <0xfc0000 0x40000>;
145 read-only;
146 };
147 };
148 };
149 };
150
151 &pci0 {
152 status = "okay";
153
154 pinctrl-0 = <&pci_gnt1_pins>, <&pci_gnt2_pins>,
155 <&pci_gnt3_pins>, <&pci_gnt4_pins>,
156 <&pci_req1_pins>, <&pci_req2_pins>,
157 <&pci_req4_pins>;
158 pinctrl-names = "default";
159
160 req-mask = <0xf>;
161 gpio-reset = <&gpio 21 GPIO_ACTIVE_LOW>;
162
163 wifi@0,0 {
164 compatible = "pci0,0";
165 reg = <0x7000 0 0 0 0>;
166 qca,no-eeprom; /* load from ath9k-eeprom-pci-0000:00:0e.0.bin */
167 };
168 };