lantiq: add support for AVM Fritzbox 7490
[openwrt/staging/svanheule.git] / target / linux / lantiq / files / arch / mips / boot / dts / lantiq / vr9_avm_fritzxx90.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "vr9.dtsi"
4
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/mips/lantiq_rcu_gphy.h>
7
8 / {
9 chosen {
10 bootargs = "console=ttyLTQ0,115200";
11 };
12
13 memory@0 {
14 device_type = "memory";
15 reg = <0x0 0x10000000>;
16 };
17
18 aliases: aliases {
19 led-boot = &led_power_green;
20 led-failsafe = &led_info_red;
21 led-running = &led_power_green;
22 led-upgrade = &led_info_red;
23 };
24
25 keys {
26 compatible = "gpio-keys-polled";
27 poll-interval = <100>;
28
29 power {
30 label = "power";
31 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
32 linux,code = <KEY_POWER>;
33 };
34
35 wifi {
36 label = "wifi";
37 gpios = <&gpio 29 GPIO_ACTIVE_LOW>;
38 linux,code = <KEY_RFKILL>;
39 };
40 };
41
42 leds: leds {
43 compatible = "gpio-leds";
44
45 led_power_green: power_green {
46 label = "green:power";
47 gpios = <&gpio 45 GPIO_ACTIVE_LOW>;
48 default-state = "keep";
49 };
50
51 led_info_green: info_green {
52 label = "green:info";
53 gpios = <&gpio 33 GPIO_ACTIVE_LOW>;
54 };
55
56 led_info_red: info_red {
57 label = "red:info";
58 gpios = <&gpio 46 GPIO_ACTIVE_LOW>;
59 };
60 };
61 };
62
63 &gphy0 {
64 lantiq,gphy-mode = <GPHY_MODE_GE>;
65 };
66
67 &gphy1 {
68 lantiq,gphy-mode = <GPHY_MODE_GE>;
69 };
70
71 &gpio {
72 pinctrl-names = "default";
73 pinctrl-0 = <&state_default>;
74 gpio-ranges = <&gpio 0 0 56>;
75
76 state_default: pinmux {
77 phy-rst {
78 lantiq,pins = "io32", "io44";
79 lantiq,pull = <0>;
80 lantiq,open-drain;
81 lantiq,output = <1>;
82 };
83
84 pcie-rst {
85 lantiq,pins = "io21";
86 lantiq,open-drain;
87 lantiq,output = <1>;
88 };
89 };
90
91 usb-vbus {
92 gpio-hog;
93 line-name = "usb-vbus";
94 gpios = <14 GPIO_ACTIVE_HIGH>;
95 output-high;
96 };
97
98 pcie-enable-dev {
99 gpio-hog;
100 line-name = "pcie-enable-dev";
101 gpios = <22 GPIO_ACTIVE_LOW>;
102 output-low;
103 };
104 };
105
106 &gswip {
107 pinctrl-0 = <&mdio_pins>;
108 pinctrl-names = "default";
109 };
110
111 &spi {
112 status = "okay";
113
114 flash@4 {
115 compatible = "jedec,spi-nor";
116 reg = <4>;
117 spi-max-frequency = <10000000>;
118
119 partitions {
120 compatible = "fixed-partitions";
121 #address-cells = <1>;
122 #size-cells = <1>;
123
124 urlader: partition@0 {
125 reg = <0x0 0x40000>;
126 label = "urlader";
127 read-only;
128 };
129
130 partition@40000 {
131 reg = <0x40000 0x60000>;
132 label = "tffs (1)";
133 read-only;
134 };
135
136 partition@a0000 {
137 reg = <0xa0000 0x60000>;
138 label = "tffs (2)";
139 read-only;
140 };
141 };
142 };
143 };
144
145 &localbus {
146 nand1: nand@1 {
147 compatible = "lantiq,nand-xway";
148 bank-width = <2>;
149 reg = <0x1 0x0 0x2000000>;
150
151 partitions {
152 compatible = "fixed-partitions";
153 #address-cells = <1>;
154 #size-cells = <1>;
155
156 partition@0 {
157 label = "kernel";
158 reg = <0x0 0x400000>;
159 };
160
161 partition@400000 {
162 label = "ubi";
163 reg = <0x400000 0x1fc00000>;
164 };
165 };
166 };
167 };
168
169 &pcie0 {
170 status = "okay";
171
172 gpio-reset = <&gpio 21 GPIO_ACTIVE_LOW>;
173 lantiq,switch-pcie-endianess;
174 };