lantiq: add swconfig to the default packages
[oweals/openwrt.git] / target / linux / lantiq / dts / DGN3500.dtsi
1 #include "ar9.dtsi"
2
3 #include <dt-bindings/input/input.h>
4
5 / {
6         chosen {
7                 bootargs = "root= console=ttyLTQ0,115200";
8         };
9
10         aliases {
11                 led-boot = &power_green;
12                 led-failsafe = &power_red;
13                 led-running = &power_green;
14
15                 led-dsl = &dsl;
16                 led-internet = &internet;
17                 led-usb = &usb;
18                 led-wifi = &wifi;
19         };
20
21         memory@0 {
22                 reg = <0x0 0x4000000>;
23         };
24
25         fpi@10000000 {
26                 gpio: pinmux@E100B10 {
27                         pinctrl-names = "default";
28                         pinctrl-0 = <&state_default>;
29
30                         state_default: pinmux {
31                                 exin {
32                                         lantiq,groups = "exin1";
33                                         lantiq,function = "exin";
34                                 };
35                                 pci {
36                                         lantiq,groups = "gnt1", "req1";
37                                         lantiq,function = "pci";
38                                 };
39                                 pci-in {
40                                         lantiq,groups = "req1";
41                                         lantiq,output = <0>;
42                                         lantiq,open-drain = <1>;
43                                         lantiq,pull = <2>;
44                                 };
45                                 pci-out {
46                                         lantiq,groups = "gnt1";
47                                         lantiq,output = <1>;
48                                         lantiq,pull = <0>;
49                                 };
50                         };
51                         pins_spi_default: pins_spi_default {
52                                 spi_in {
53                                         lantiq,groups = "spi_di";
54                                         lantiq,function = "spi";
55                                 };
56                                 spi_out {
57                                         lantiq,groups = "spi_do", "spi_clk",
58                                                 "spi_cs4";
59                                         lantiq,function = "spi";
60                                         lantiq,output = <1>;
61                                 };
62                         };
63                 };
64
65                 etop@E180000 {
66                         phy-mode = "mii";
67                 };
68
69                 ifxhcd@E101000 {
70                         status = "okay";
71                 };
72
73                 pci@E105400 {
74                         status = "okay";
75                         gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
76                 };
77         };
78
79         ath9k_eep {
80                 compatible = "ath9k,eeprom";
81                 ath,eep-flash = <&ath9k_cal 0xf000>;
82                 ath,pci-slot = <14>;
83                 ath,eep-endian;
84                 ath,eep-swap;
85         };
86
87         rtl8366rb {
88                 compatible = "rtl8366rb";
89                 gpio-sda = <&gpio 35 GPIO_ACTIVE_HIGH>;
90                 gpio-sck = <&gpio 37 GPIO_ACTIVE_HIGH>;
91         };
92
93         gpio-keys-polled {
94                 compatible = "gpio-keys-polled";
95                 #address-cells = <1>;
96                 #size-cells = <0>;
97                 poll-interval = <100>;
98
99                 rfkill {
100                         label = "rfkill";
101                         gpios = <&gpio 36 GPIO_ACTIVE_LOW>;
102                         linux,code = <KEY_RFKILL>;
103                 };
104                 wps {
105                         label = "wps";
106                         gpios = <&gpio 54 GPIO_ACTIVE_LOW>;
107                         linux,code = <KEY_WPS_BUTTON>;
108                 };
109                 reset {
110                         label = "reset";
111                         gpios = <&gpio 53 GPIO_ACTIVE_LOW>;
112                         linux,code = <KEY_RESTART>;
113                 };
114         };
115
116         gpio-leds {
117                 compatible = "gpio-leds";
118                 internet: internet {
119                         label = "dgn3500:green:internet";
120                         gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
121                 };
122                 /*
123                         internet red is missing
124                 */
125                 dsl: dsl {
126                         label = "dgn3500:green:dsl";
127                         gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
128                 };
129                 usb: usb {
130                         label = "dgn3500:green:usb";
131                         gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
132                 };
133                 power_green: power {
134                         label = "dgn3500:green:power";
135                         gpios = <&gpio 34 GPIO_ACTIVE_LOW>;
136                         default-state = "keep";
137                 };
138                 power_red: power2 {
139                         label = "dgn3500:red:power";
140                         gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
141                 };
142                 /*
143                         power amber is missing
144                 */
145                 wifi: wifi {
146                         label = "dgn3500:blue:wireless";
147                         gpios = <&gpio 51 GPIO_ACTIVE_LOW>;
148                 };
149                 wps {
150                         label = "dgn3500:green:wps";
151                         gpios = <&gpio 52 GPIO_ACTIVE_LOW>;
152                 };
153         };
154 };
155
156 &spi {
157         pinctrl-names = "default";
158         pinctrl-0 = <&pins_spi_default>;
159
160         status = "ok";
161
162         m25p80@4 {
163                 #address-cells = <1>;
164                 #size-cells = <1>;
165                 compatible = "jedec,spi-nor";
166                 reg = <4 0>;
167                 spi-max-frequency = <20000000>;
168
169                 partitions {
170                         compatible = "fixed-partitions";
171                         #address-cells = <1>;
172                         #size-cells = <1>;
173
174                         partition@0 {
175                                 reg = <0x0 0x10000>;
176                                 label = "uboot";
177                                 read-only;
178                         };
179
180                         partition@10000 {
181                                 reg = <0x10000 0x10000>;
182                                 label = "uboot-env";
183                                 read-only;
184                         };
185
186                         ath9k_cal: partition@20000 {
187                                 reg = <0x20000 0x10000>;
188                                 label = "calibration";
189                                 read-only;
190                         };
191
192                         partition@50000 {
193                                 reg = <0x50000 0xfa0000>;
194                                 label = "firmware";
195                         };
196                 };
197         };
198 };