treewide: dts: use keycode defines from input dt-binding
[oweals/openwrt.git] / target / linux / lantiq / dts / BTHOMEHUBV3A.dts
1 /dts-v1/;
2
3 #include "ar9.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8         model = "BTHOMEHUBV3A - BT Home Hub 3A";  /* SoC: Lantiq ar9 @ 333MHz */
9
10         chosen {
11                 bootargs = "console=ttyLTQ0,115200 init=/etc/preinit";
12         };
13
14         aliases {
15                 led-boot = &power_orange;
16                 led-failsafe = &power_red;
17                 led-running = &power_blue;
18
19                 led-internet = &broadband_blue;
20                 led-wifi = &wireless_blue;
21         };
22
23         memory@0 {                                /* RAM: Samsung K4H511638F-LC 64MB */
24                 reg = <0x0 0x4000000>;
25         };
26
27         sram@1F000000 {
28                 vmmc@107000 {
29                         status = "okay";
30                         gpios = <&gpio 31 GPIO_ACTIVE_HIGH>;
31                 };
32         };
33
34         fpi@10000000 {
35                 localbus@0 {
36                         nand-parts@0 {            /* NAND Flash: Samsung K9F5608U0D-JIB0 32MB */
37                                 compatible = "gen_nand", "lantiq,nand-xway";
38                                 lantiq,cs = <1>;
39                                 bank-width = <2>;
40                                 reg = <1 0x0 0x2000000 >;
41                                 #address-cells = <1>;
42                                 #size-cells = <1>;
43                                 req-mask = <0x1>;  /* PCI request lines to mask during NAND access */
44
45                                 partitions {
46                                         compatible = "fixed-partitions";
47                                         #address-cells = <1>;
48                                         #size-cells = <1>;
49
50                                         partition@0 {
51                                                 label = "preboot";
52                                                 reg = <0x00000 0x8000>;
53                                                 read-only;
54                                         };
55                                         partition@8000 {
56                                                 label = "u-boot";
57                                                 reg = <0x8000 0x05c000>;
58                                                 read-only;
59                                         };
60                                         partition@64000 {
61                                                 label = "uboot_env";
62                                                 reg = <0x64000 0x004000>;
63                                         };
64                                         ath9k_cal: partition@68000 {
65                                                 label = "art-copy";
66                                                 reg = <0x68000 0x004000>;
67                                         };
68                                         partition@6c000 {
69                                                 label = "kernel";
70                                                 reg = <0x6c000 0x200000>;
71                                         };
72                                         partition@26c000 {
73                                                 label = "ubi";
74                                                 reg = <0x26c000 0x1d94000>;
75                                         };
76                                 };
77                         };
78
79                         ath9k_eep {
80                                 compatible = "ath9k,eeprom";
81                                 ath,eep-flash = <&ath9k_cal 0x0000>;
82                                 ath,pci-slot = <14>;
83                                 ath,eep-endian;
84                         };
85                 };
86
87                 gpio: pinmux@E100B10 {
88                         pinctrl-names = "default";
89                         pinctrl-0 = <&state_default>;
90
91                         state_default: pinmux {
92                                 nand_out {
93                                         lantiq,groups = "nand cle", "nand ale";
94                                         lantiq,function = "ebu";
95                                         lantiq,output = <1>;
96                                         lantiq,open-drain = <0>;
97                                         lantiq,pull = <0>;
98                                 };
99                                 nand_cs1 {
100                                         lantiq,groups = "nand cs1";
101                                         lantiq,function = "ebu";
102                                         lantiq,open-drain = <0>;
103                                         lantiq,pull = <0>;
104                                 };
105
106                                 pci_in {
107                                         lantiq,groups = "req1";
108                                         lantiq,function = "pci";
109                                         lantiq,output = <0>;
110                                         lantiq,open-drain = <1>;
111                                         lantiq,pull = <2>;
112                                 };
113                                 pci_out {
114                                         lantiq,groups = "gnt1";
115                                         lantiq,function = "pci";
116                                         lantiq,output = <1>;
117                                         lantiq,open-drain = <0>;
118                                         lantiq,pull = <0>;
119                                 };
120
121                                 pci_rst {
122                                         lantiq,pins = "io21";
123                                         lantiq,output = <1>;
124                                         lantiq,open-drain = <0>;
125                                 };
126                         };
127                 };
128
129                 etop@E180000 {
130                         phy-mode = "rgmii";
131                 };
132
133                 ifxhcd@E101000 {
134                         status = "okay";
135                         gpios = <&gpio 33 GPIO_ACTIVE_HIGH>;
136                 };
137
138                 pci@E105400 {
139                         status = "okay";
140                         gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
141                 };
142         };
143
144         gpio-keys-polled {
145                 compatible = "gpio-keys-polled";
146                 #address-cells = <1>;
147                 #size-cells = <0>;
148                 poll-interval = <100>;
149                 reset {
150                         label = "reset";
151                         gpios = <&gpio 54 GPIO_ACTIVE_LOW>;
152                         linux,code = <KEY_RESTART>;
153                 };
154                 restart {
155                         label = "restart";
156                         gpios = <&gpio 52 GPIO_ACTIVE_LOW>;
157                         linux,code = <KEY_RESTART>;
158                 };
159                 wps {
160                         label = "wps";
161                         gpios = <&gpio 53 GPIO_ACTIVE_LOW>;
162                         linux,code = <KEY_WPS_BUTTON>;
163                 };
164         };
165
166         gpio-leds {
167                 compatible = "gpio-leds";
168
169                 wireless-red {
170                         label = "bthomehubv3a:red:wireless";
171                         gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
172                 };
173                 wireless-orange {
174                         label = "bthomehubv3a:orange:wireless";
175                         gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
176                 };
177                 wireless_blue: wireless-blue {
178                         label = "bthomehubv3a:blue:wireless";
179                         gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
180                 };
181
182                 broadband-red {
183                         label = "bthomehubv3a:red:broadband";
184                         gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
185                 };
186                 broadband-orange {
187                         label = "bthomehubv3a:orange:broadband";
188                         gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
189                 };
190                 broadband_blue: broadband-blue {
191                         label = "bthomehubv3a:blue:broadband";
192                         gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
193                 };
194
195                 power_red: power-red {
196                         label = "bthomehubv3a:red:power";
197                         gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
198                 };
199                 power_orange: power-orange {
200                         label = "bthomehubv3a:orange:power";
201                         gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
202                         default-state = "keep";
203                 };
204                 power_blue: power-blue {
205                         label = "bthomehubv3a:blue:power";
206                         gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
207                 };
208         };
209 };