rootfs: fix USE_APK detection
[openwrt/openwrt.git] / target / linux / ramips / dts / rt3662_dlink_dir-645.dts
1 #include "rt3883.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "dlink,dir-645", "ralink,rt3662-soc", "ralink,rt3883-soc";
8 model = "D-Link DIR-645";
9
10 aliases {
11 led-boot = &led_wps;
12 led-failsafe = &led_wps;
13 led-running = &led_wps;
14 led-upgrade = &led_wps;
15 };
16
17 rtl8367b {
18 compatible = "realtek,rtl8367b";
19 gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
20 gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
21 realtek,extif1 = <1 0 1 1 1 1 1 1 2>;
22 };
23
24 keys {
25 compatible = "gpio-keys-polled";
26 poll-interval = <100>;
27
28 reset {
29 label = "reset";
30 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
31 linux,code = <KEY_RESTART>;
32 };
33
34 wps {
35 label = "wps";
36 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
37 linux,code = <KEY_WPS_BUTTON>;
38 };
39 };
40
41 leds {
42 compatible = "gpio-leds";
43
44 inet {
45 label = "green:inet";
46 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
47 };
48
49 led_wps: wps {
50 label = "green:wps";
51 gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
52 };
53 };
54
55 gpio_export {
56 compatible = "gpio-export";
57 #size-cells = <0>;
58
59 usb {
60 gpio-export,name = "usb";
61 gpio-export,output = <1>;
62 gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
63 };
64 };
65 };
66
67 &gpio1 {
68 status = "okay";
69 };
70
71 &spi0 {
72 status = "okay";
73
74 flash@0 {
75 compatible = "jedec,spi-nor";
76 reg = <0>;
77 spi-max-frequency = <25000000>;
78
79 partitions {
80 compatible = "fixed-partitions";
81 #address-cells = <1>;
82 #size-cells = <1>;
83
84 partition@0 {
85 label = "uboot";
86 reg = <0x0 0x30000>;
87 read-only;
88 };
89
90 partition@30000 {
91 label = "uboot-env";
92 reg = <0x30000 0x4000>;
93 read-only;
94 };
95
96 factory: partition@34000 {
97 label = "factory";
98 reg = <0x34000 0x4000>;
99 read-only;
100 };
101
102 partition@38000 {
103 label = "nvram";
104 reg = <0x38000 0x8000>;
105 read-only;
106 };
107
108 partition@40000 {
109 label = "devdata";
110 reg = <0x40000 0x10000>;
111 };
112
113 partition@50000 {
114 compatible = "seama";
115 label = "firmware";
116 reg = <0x50000 0x7b0000>;
117 };
118 };
119 };
120 };
121
122 &state_default {
123 gpio {
124 groups = "i2c", "jtag", "uartf";
125 function = "gpio";
126 };
127 };
128
129 &ethernet {
130 nvmem-cells = <&macaddr_factory_4>;
131 nvmem-cell-names = "mac-address";
132
133 port@0 {
134 mediatek,fixed-link = <1000 1 1 0>;
135 };
136 };
137
138 &wmac {
139 ralink,5ghz = <0>;
140 ralink,mtd-eeprom = <&factory 0x0>;
141 };
142
143 &ehci {
144 status = "okay";
145 };
146
147 &ohci {
148 status = "okay";
149 };
150
151 &factory {
152 compatible = "nvmem-cells";
153 #address-cells = <1>;
154 #size-cells = <1>;
155
156 macaddr_factory_4: macaddr@4 {
157 reg = <0x4 0x6>;
158 };
159 };