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