07950baed8ff782b2eb4a6d558399235dd81c50a
[openwrt/openwrt.git] / target / linux / ramips / dts / Newifi-D1.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
9 model = "Newifi-D1";
10
11 memory@0 {
12 device_type = "memory";
13 reg = <0x0 0x10000000>;
14 };
15
16 chosen {
17 bootargs = "console=ttyS0,115200";
18 };
19
20 gpio-leds {
21 compatible = "gpio-leds";
22
23 status-red {
24 label = "newifi-d1:red:status";
25 gpios = <&gpio0 14 1>;
26 };
27
28 status-green {
29 label = "newifi-d1:green:status";
30 gpios = <&gpio0 13 1>;
31 };
32
33 statys-blue {
34 label = "newifi-d1:blue:status";
35 gpios = <&gpio0 16 1>;
36 };
37 };
38
39 gpio-keys-polled {
40 compatible = "gpio-keys-polled";
41 #address-cells = <1>;
42 #size-cells = <0>;
43 poll-interval = <20>;
44
45 reset {
46 label = "reset";
47 gpios = <&gpio0 15 1>;
48 linux,code = <KEY_RESTART>;
49 };
50 };
51
52 gpio_export {
53 compatible = "gpio-export";
54 #size-cells = <0>;
55
56 usb2power {
57 gpio-export,name = "usb2power";
58 gpio-export,output = <1>;
59 gpios = <&gpio0 9 0>;
60 };
61
62 usb3power {
63 gpio-export,name = "usb3power";
64 gpio-export,output = <1>;
65 gpios = <&gpio0 11 0>;
66 };
67 };
68 };
69
70 &sdhci {
71 status = "okay";
72 pinctrl-names = "default";
73 pinctrl-0 = <&sdhci_pins>;
74 };
75
76 &xhci {
77 status = "okay";
78 };
79
80 &spi0 {
81 status = "okay";
82
83 m25p80@0 {
84 #address-cells = <1>;
85 #size-cells = <1>;
86 compatible = "jedec,spi-nor";
87 reg = <0>;
88 linux,modalias = "m25p80";
89 spi-max-frequency = <10000000>;
90
91 partition@0 {
92 label = "u-boot";
93 reg = <0x0 0x30000>;
94 read-only;
95 };
96
97 partition@30000 {
98 label = "u-boot-env";
99 reg = <0x30000 0x10000>;
100 read-only;
101 };
102
103 factory: partition@40000 {
104 label = "factory";
105 reg = <0x40000 0x10000>;
106 read-only;
107 };
108
109 partition@50000 {
110 label = "firmware";
111 reg = <0x50000 0x2000000>;
112 };
113 };
114 };
115
116 &pcie {
117 status = "okay";
118
119 pcie0 {
120 mt76@0,0 {
121 reg = <0x0000 0 0 0 0>;
122 device_type = "pci";
123 mediatek,mtd-eeprom = <&factory 0x8000>;
124 mediatek,2ghz = <0>;
125 };
126 };
127
128 pcie1 {
129 mt76@1,0 {
130 reg = <0x0000 0 0 0 0>;
131 device_type = "pci";
132 mediatek,mtd-eeprom = <&factory 0x0000>;
133 mediatek,5ghz = <0>;
134 };
135 };
136 };
137
138 &ethernet {
139 mtd-mac-address = <&factory 0xe000>;
140 };
141
142
143
144 &pinctrl {
145 state_default: pinctrl0 {
146 gpio {
147 ralink,group = "wdt", "rgmii2", "jtag", "uart2", "uart3", "i2c";
148 ralink,function = "gpio";
149 };
150 };
151 };