213db93159b09d85f1da2ac0f008c2509f6da538
[openwrt/staging/stintel.git] / target / linux / ramips / dts / NBG-419N2.dts
1 /dts-v1/;
2
3 #include "rt3352.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "zyxel,nbg-419n-v2", "ralink,rt3352-soc";
10 model = "ZyXEL NBG-419N v2";
11
12 aliases {
13 led-status = &led_power;
14 };
15
16 palmbus@10000000 {
17 spi@b00 {
18 status = "okay";
19 m25p80@0 {
20 compatible = "jedec,spi-nor";
21 reg = <0 0>;
22 spi-max-frequency = <10000000>;
23
24 partitions {
25 compatible = "fixed-partitions";
26 #address-cells = <1>;
27 #size-cells = <1>;
28
29 partition@0 {
30 label = "u-boot";
31 reg = <0x0 0x30000>;
32 read-only;
33 };
34
35 partition@30000 {
36 label = "u-boot-env";
37 reg = <0x30000 0x10000>;
38 read-only;
39 };
40
41 factory: partition@40000 {
42 label = "factory";
43 reg = <0x40000 0x10000>;
44 read-only;
45 };
46
47 partition@50000 {
48 label = "firmware";
49 reg = <0x50000 0x7b0000>;
50 };
51 };
52 };
53 };
54 };
55
56 gpio-leds {
57 compatible = "gpio-leds";
58
59 led_power: power {
60 label = "nbg-419n2:green:power";
61 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
62 };
63
64 wps {
65 label = "nbg-419n2:green:wps";
66 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
67 };
68
69 usb {
70 label = "nbg-419n2:green:usb";
71 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
72 trigger-sources = <&ohci_port1>, <&ehci_port1>;
73 linux,default-trigger = "usbport";
74 };
75 };
76
77 gpio-keys-polled {
78 compatible = "gpio-keys-polled";
79 poll-interval = <20>;
80 reset {
81 label = "reset";
82 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
83 linux,code = <KEY_RESTART>;
84 };
85 wps {
86 label = "wps";
87 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
88 linux,code = <KEY_WPS_BUTTON>;
89 };
90 rfkill {
91 label = "rfkill";
92 linux,input-type = <EV_SW>;
93 gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
94 linux,code = <KEY_RFKILL>;
95 };
96 };
97 };
98
99 &pinctrl {
100 state_default: pinctrl0 {
101 gpio {
102 ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
103 ralink,function = "gpio";
104 };
105 };
106 };
107
108 &ethernet {
109 mtd-mac-address = <&factory 0x28>;
110 };
111
112 &esw {
113 mediatek,portmap = <0x2f>;
114 };
115
116 &wmac {
117 ralink,mtd-eeprom = <&factory 0>;
118 };
119
120 &ehci {
121 status = "okay";
122 };
123
124 &ohci {
125 status = "okay";
126 };