ramips: move compatible for Ubiquiti Edgerouter X to DTS file
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / mt7628an_d-team_pbr-d1.dts
1 /dts-v1/;
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "d-team,pbr-d1", "mediatek,mt7628an-soc";
10 model = "PBR-D1";
11
12 aliases {
13 led-boot = &led_power;
14 led-failsafe = &led_power;
15 led-running = &led_power;
16 led-upgrade = &led_power;
17 };
18
19 chosen {
20 bootargs = "console=ttyS0,115200";
21 };
22
23 aliases {
24 serial0 = &uart2;
25 };
26
27 leds {
28 compatible = "gpio-leds";
29
30 usb {
31 label = "pbr-d1:orange:usb";
32 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
33 trigger-sources = <&ohci_port1>, <&ehci_port1>;
34 linux,default-trigger = "usbport";
35 };
36
37 led_power: power {
38 label = "pbr-d1:orange:power";
39 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
40 default-state = "on";
41 };
42 };
43
44 keys {
45 compatible = "gpio-keys";
46
47 reset {
48 label = "reset";
49 gpios = <&gpio1 38 GPIO_ACTIVE_LOW>;
50 linux,code = <KEY_RESTART>;
51 };
52 };
53
54 wgpio: gpio-wifi {
55 compatible = "mediatek,gpio-wifi";
56 #address-cells = <1>;
57 #size-cells = <0>;
58 gpio-controller;
59 #gpio-cells = <2>;
60 };
61 };
62
63 &state_default {
64 gpio {
65 ralink,group = "gpio";
66 ralink,function = "gpio";
67 };
68
69 i2c {
70 ralink,group = "i2c";
71 ralink,function = "gpio";
72 };
73
74 i2s {
75 ralink,group = "i2s";
76 ralink,function = "gpio";
77 };
78
79 spis {
80 ralink,group = "spis";
81 ralink,function = "gpio";
82 };
83
84 wdt {
85 ralink,group = "wdt";
86 ralink,function = "gpio";
87 };
88 };
89
90 &spi0 {
91 status = "okay";
92
93 pinctrl-names = "default";
94 pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
95
96 m25p80@0 {
97 compatible = "jedec,spi-nor";
98 reg = <0>;
99 spi-max-frequency = <40000000>;
100
101 partitions {
102 compatible = "fixed-partitions";
103 #address-cells = <1>;
104 #size-cells = <1>;
105
106 partition@0 {
107 label = "u-boot";
108 reg = <0x0 0x30000>;
109 read-only;
110 };
111
112 partition@30000 {
113 label = "u-boot-env";
114 reg = <0x30000 0x10000>;
115 };
116
117 factory: partition@40000 {
118 label = "factory";
119 reg = <0x40000 0x10000>;
120 read-only;
121 };
122
123 partition@50000 {
124 compatible = "denx,uimage";
125 label = "firmware";
126 reg = <0x50000 0x0fb0000>;
127 };
128 };
129 };
130
131 spidev@1 {
132 #address-cells = <1>;
133 #size-cells = <1>;
134 compatible = "linux,spidev";
135 reg = <1>;
136 spi-max-frequency = <40000000>;
137 };
138 };
139
140 &i2c {
141 status = "okay";
142 };
143
144 &uart1 {
145 status = "okay";
146 };
147
148 &uart2 {
149 status = "okay";
150 };
151
152 &pwm {
153 status = "okay";
154 };
155
156 &ethernet {
157 mtd-mac-address = <&factory 0x28>;
158 };
159
160 &sdhci {
161 status = "okay";
162 mediatek,cd-high;
163 };