0bfe48f3d4e8e8f48e48f6a5703673c29d4a351e
[openwrt/openwrt.git] / target / linux / ramips / dts / HT-TM02.dts
1 /dts-v1/;
2
3 #include "rt5350.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "HT-TM02", "ralink,rt5350-soc";
9 model = "HooToo HT-TM02";
10
11 gpio-leds {
12 compatible = "gpio-leds";
13
14 wlan {
15 label = "ht-tm02:blue:wlan";
16 gpios = <&gpio0 7 1>;
17 };
18
19 lan {
20 label = "ht-tm02:green:lan";
21 gpios = <&gpio0 12 1>;
22 };
23 };
24
25 gpio-keys-polled {
26 compatible = "gpio-keys-polled";
27 #address-cells = <1>;
28 #size-cells = <0>;
29 poll-interval = <20>;
30
31 reset {
32 label = "reset";
33 gpios = <&gpio0 10 1>;
34 linux,code = <KEY_RESTART>;
35 };
36
37 modeswitch {
38 label = "modeswitch";
39 gpios = <&gpio0 14 1>;
40 linux,code = <BTN_0>;
41 linux,input-type = <EV_SW>;
42 };
43 };
44 };
45
46 &gpio0 {
47 status = "okay";
48 };
49
50 &spi0 {
51 status = "okay";
52
53 m25p80@0 {
54 #address-cells = <1>;
55 #size-cells = <1>;
56 compatible = "jedec,spi-nor";
57 reg = <0>;
58 spi-max-frequency = <10000000>;
59
60 partition@0 {
61 label = "u-boot";
62 reg = <0x0 0x30000>;
63 read-only;
64 };
65
66 partition@30000 {
67 label = "u-boot-env";
68 reg = <0x30000 0x10000>;
69 read-only;
70 };
71
72 factory: partition@40000 {
73 label = "factory";
74 reg = <0x40000 0x10000>;
75 read-only;
76 };
77
78 partition@50000 {
79 label = "firmware";
80 reg = <0x50000 0x7b0000>;
81 };
82 };
83 };
84
85 &pinctrl {
86 state_default: pinctrl0 {
87 gpio {
88 ralink,group = "i2c", "jtag", "uartf";
89 ralink,function = "gpio";
90 };
91 };
92 };
93
94 &ethernet {
95 mtd-mac-address = <&factory 0x28>;
96 };
97
98 &esw {
99 mediatek,portmap = <0x10>;
100 mediatek,portdisable = <0x2f>;
101 };
102
103 &wmac {
104 ralink,mtd-eeprom = <&factory 0>;
105 };
106
107 &ehci {
108 status = "okay";
109 };
110
111 &ohci {
112 status = "okay";
113 };