ade64b3f46c07b0bb3e0acb033dbe3ddf0867f81
[openwrt/staging/hauke.git] / target / linux / ramips / dts / rt2880_dlink_dap-1522-a1.dts
1 #include "rt2880.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "dlink,dap-1522-a1", "ralink,rt2880-soc";
8 model = "D-Link DAP-1522 A1";
9
10 aliases {
11 led-boot = &led_status;
12 led-failsafe = &led_status;
13 led-running = &led_status;
14 led-upgrade = &led_status;
15 };
16
17 flash@bc400000 {
18 compatible = "cfi-flash";
19 reg = <0xbc400000 0x800000>;
20 bank-width = <2>;
21 device-width = <2>;
22
23 partitions {
24 compatible = "fixed-partitions";
25 #address-cells = <1>;
26 #size-cells = <1>;
27
28 partition@0 {
29 label = "uboot";
30 reg = <0x0 0x30000>;
31 read-only;
32 };
33
34 factory: partition@30000 {
35 compatible = "nvmem-cells";
36 label = "factory";
37 reg = <0x30000 0x10000>;
38 #address-cells = <1>;
39 #size-cells = <1>;
40 read-only;
41
42 eeprom_factory_2000: eeprom@2000 {
43 reg = <0x2000 0x200>;
44 };
45
46 macaddr_factory_2004: macaddr@2004 {
47 reg = <0x2004 0x6>;
48 };
49 };
50
51 partition@40000 {
52 compatible = "wrg";
53 label = "firmware";
54 reg = <0x40000 0x3a0000>;
55 };
56 };
57 };
58
59 rtl8366s {
60 compatible = "realtek,rtl8366s";
61 gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
62 gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
63 };
64
65 keys {
66 compatible = "gpio-keys-polled";
67 poll-interval = <100>;
68
69 reset {
70 label = "reset";
71 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
72 linux,code = <KEY_RESTART>;
73 };
74
75 wps {
76 label = "wps";
77 gpios = <&gpio2 16 GPIO_ACTIVE_LOW>;
78 linux,code = <KEY_WPS_BUTTON>;
79 };
80
81 ap {
82 label = "ap";
83 gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
84 linux,code = <BTN_0>;
85 linux,input-type = <EV_SW>;
86 };
87
88 bridge {
89 label = "bridge";
90 gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
91 linux,code = <BTN_1>;
92 linux,input-type = <EV_SW>;
93 };
94 };
95
96 leds {
97 compatible = "gpio-leds";
98
99 wps {
100 label = "blue:wps";
101 gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
102 };
103
104 ap {
105 label = "blue:ap";
106 gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
107 };
108
109 sta {
110 label = "red:sta";
111 gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
112 };
113
114 led_status: status {
115 label = "blue:status";
116 gpios = <&gpio2 20 GPIO_ACTIVE_LOW>;
117 };
118 };
119 };
120
121 &gpio2 {
122 status = "okay";
123 };
124
125 &state_default {
126 gpio {
127 groups = "i2c", "uartlite", "pci";
128 function = "gpio";
129 };
130 };
131
132 &ethernet {
133 status = "okay";
134 nvmem-cells = <&macaddr_factory_2004>;
135 nvmem-cell-names = "mac-address";
136
137 port@0 {
138 mediatek,fixed-link = <1000 1 1 1>;
139 };
140
141 mdio-bus {
142 status = "okay";
143
144 phy0: ethernet-phy@0 {
145 phy-mode = "mii";
146 reg = <0>;
147 };
148 };
149 };
150
151 &wmac {
152 nvmem-cells = <&eeprom_factory_2000>;
153 nvmem-cell-names = "eeprom";
154 };