lantiq: dts: assign the NAND pins to the nand-controller node
[openwrt/staging/ansuel.git] / target / linux / lantiq / files / arch / mips / boot / dts / BTHOMEHUBV2B.dts
1 /dts-v1/;
2
3 #include "danube.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "bt,homehub-v2b", "lantiq,xway", "lantiq,danube";
9 model = "BT Home Hub 2B"; /* SoC: Lantiq Danube-S PSB 50712 @ 333MHz V1.3/1.5 */
10
11 chosen {
12 bootargs = "console=ttyLTQ0,115200";
13 };
14
15 aliases {
16 led-boot = &power_orange;
17 led-failsafe = &power_red;
18 led-running = &power_blue;
19 led-upgrade = &power_blue;
20
21 led-dsl = &broadband_blue;
22 led-wifi = &wireless_blue;
23 };
24
25 memory@0 { /* RAM: Samsung K4H511638F-LC 64MB */
26 device_type = "memory";
27 reg = <0x0 0x4000000>;
28 };
29
30 keys {
31 compatible = "gpio-keys-polled";
32 poll-interval = <100>;
33
34 reset {
35 label = "reset";
36 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
37 linux,code = <KEY_RESTART>;
38 };
39 findhandset {
40 label = "findhandset";
41 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
42 linux,code = <KEY_PHONE>;
43 };
44 wps {
45 label = "wps";
46 gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
47 linux,code = <KEY_WPS_BUTTON>;
48 };
49 };
50
51 leds {
52 compatible = "gpio-leds";
53
54 upgrading-orange {
55 label = "bthomehubv2b:orange:upgrading";
56 gpios = <&gpios 5 GPIO_ACTIVE_HIGH>;
57 };
58
59 phone-orange {
60 label = "bthomehubv2b:orange:phone";
61 gpios = <&gpios 6 GPIO_ACTIVE_HIGH>;
62 };
63 phone-blue {
64 label = "bthomehubv2b:blue:phone";
65 gpios = <&gpios 7 GPIO_ACTIVE_HIGH>;
66 };
67
68 wireless-orange {
69 label = "bthomehubv2b:orange:wireless";
70 gpios = <&gpios 8 GPIO_ACTIVE_HIGH>;
71 };
72 wireless_blue: wireless-blue {
73 label = "bthomehubv2b:blue:wireless";
74 gpios = <&gpios 9 GPIO_ACTIVE_HIGH>;
75 };
76
77 broadband-red {
78 label = "bthomehubv2b:red:broadband";
79 gpios = <&gpios 10 GPIO_ACTIVE_HIGH>;
80 };
81 broadband-orange {
82 label = "bthomehubv2b:orange:broadband";
83 gpios = <&gpios 11 GPIO_ACTIVE_HIGH>;
84 };
85 broadband_blue: broadband-blue {
86 label = "bthomehubv2b:blue:broadband";
87 gpios = <&gpios 12 GPIO_ACTIVE_HIGH>;
88 };
89
90 power_red: power-red {
91 label = "bthomehubv2b:red:power";
92 gpios = <&gpios 13 GPIO_ACTIVE_HIGH>;
93 };
94 power_orange: power-orange {
95 label = "bthomehubv2b:orange:power";
96 gpios = <&gpios 14 GPIO_ACTIVE_HIGH>;
97 default-state = "keep";
98 };
99 power_blue: power-blue {
100 label = "bthomehubv2b:blue:power";
101 gpios = <&gpios 15 GPIO_ACTIVE_HIGH>;
102 };
103 };
104 };
105
106 &gpio {
107 pinctrl-names = "default";
108 pinctrl-0 = <&state_default>;
109
110 state_default: pinmux {
111 exin {
112 lantiq,groups = "exin1";
113 lantiq,function = "exin";
114 };
115 pci_in {
116 lantiq,groups = "req1";
117 lantiq,function = "pci";
118 lantiq,output = <0>;
119 lantiq,open-drain = <1>;
120 lantiq,pull = <2>;
121 };
122 pci_out {
123 lantiq,groups = "gnt1";
124 lantiq,function = "pci";
125 lantiq,output = <1>;
126 lantiq,open-drain = <0>;
127 lantiq,pull = <0>;
128 };
129
130 pci_rst {
131 lantiq,pins = "io21";
132 lantiq,output = <1>;
133 lantiq,open-drain = <0>;
134 };
135
136 btn_in {
137 lantiq,pins = "io2", "io15", "io22";
138 lantiq,output = <0>;
139 lantiq,open-drain = <1>;
140 lantiq,pull = <2>;
141 };
142 };
143 };
144
145 &gpios {
146 status = "okay";
147 };
148
149 &gsw {
150 phy-mode = "rmii";
151 };
152
153 &localbus {
154 flash@0 { /* NOR Flash: Spansion S29AL004D 512KB */
155 compatible = "lantiq,nor"; /* "AMD AM29LV400BB" compatible on 3.3.8 */
156 lantiq,cs = <0>;
157 bank-width = <2>;
158 reg = <0 0x0 0x80000>;
159
160 partitions {
161 compatible = "fixed-partitions";
162 #address-cells = <1>;
163 #size-cells = <1>;
164
165 partition@0 {
166 label = "uboot";
167 reg = <0x00000 0x40000>; /* 256KB */
168 };
169
170 partition@40000 {
171 label = "uboot_env";
172 reg = <0x40000 0x10000>; /* 64KB */
173 };
174
175 partition@50000 {
176 label = "rg_conf_1";
177 reg = <0x50000 0x10000>;
178 };
179
180 partition@60000 {
181 label = "rg_conf_2";
182 reg = <0x60000 0x10000>;
183 };
184
185 partition@70000 {
186 label = "rg_conf_factory";
187 reg = <0x70000 0x10000>;
188 };
189 };
190 };
191
192 flash@1 { /* NAND Flash: Samsung K9F5608U0D-JIB0 32MB */
193 compatible = "lantiq,nand-xway";
194 lantiq,cs = <1>;
195 bank-width = <2>;
196 reg = <1 0x0 0x2000000 >;
197 req-mask = <0x1>; /* PCI request lines to mask during NAND access */
198
199 pinctrl-0 = <&nand_pins>, <&nand_cs1_pins>;
200 pinctrl-names = "default";
201
202 partitions {
203 compatible = "fixed-partitions";
204 #address-cells = <1>;
205 #size-cells = <1>;
206
207 ath9k_cal: partition@0 {
208 label = "art"; /* Atheros 9160 wifi b/g/n radio EEPROM */
209 reg = <0x00000 0x4000>;
210 read-only;
211 };
212
213 partition@4000 {
214 label = "kernel";
215 reg = <0x4000 0x200000>;
216 };
217
218 partition@164000 {
219 label = "ubi";
220 reg = <0x204000 0x1dfc000>;
221 };
222 };
223 };
224 };
225
226 &pci0 {
227 status = "okay";
228 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
229
230 wifi@168c,0027 {
231 compatible = "pci168c,0027";
232 reg = <0x7000 0 0 0 0>;
233 qca,no-eeprom; /* load from ath9k-eeprom-pci-0000:00:0e.0.bin */
234 };
235 };
236
237 &usb_phy {
238 status = "okay";
239 };
240
241 &usb {
242 status = "okay";
243 };
244
245 &vmmc {
246 status = "okay";
247 gpios = <&gpio 31 GPIO_ACTIVE_HIGH>;
248 };