cf86bbb7e67b1c521c279367ee9e99fee88fae85
[openwrt/openwrt.git] / target / linux / ramips / dts / UBNT-ERX.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "UBNT-ERX";
10
11 memory@0 {
12 device_type = "memory";
13 reg = <0x0 0x10000000>;
14 };
15
16 chosen {
17 bootargs = "console=ttyS0,57600";
18 };
19
20 gpio-keys-polled {
21 compatible = "gpio-keys-polled";
22 #address-cells = <1>;
23 #size-cells = <0>;
24 poll-interval = <20>;
25
26 reset {
27 label = "reset";
28 gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
29 linux,code = <KEY_RESTART>;
30 };
31 };
32 };
33
34 &ethernet {
35 mtd-mac-address = <&factory 0x22>;
36 };
37
38 &nand {
39 status = "okay";
40
41 partition@0 {
42 label = "u-boot";
43 reg = <0x0 0x80000>;
44 read-only;
45 };
46
47 partition@80000 {
48 label = "u-boot-env";
49 reg = <0x80000 0x60000>;
50 read-only;
51 };
52
53 factory: partition@e0000 {
54 label = "factory";
55 reg = <0xe0000 0x60000>;
56 };
57
58 partition@140000 {
59 label = "kernel1";
60 reg = <0x140000 0x300000>;
61 };
62
63 partition@440000 {
64 label = "kernel2";
65 reg = <0x440000 0x300000>;
66 };
67
68 partition@740000 {
69 label = "ubi";
70 reg = <0x740000 0xf7c0000>;
71 };
72 };
73
74 &pinctrl {
75 state_default: pinctrl0 {
76 gpio {
77 ralink,group = "uart2", "uart3", "i2c", "pcie", "rgmii2", "jtag";
78 ralink,function = "gpio";
79 };
80 };
81 };
82
83 &spi0 {
84 /* This board has 2Mb spi flash soldered in and visible
85 from manufacturer's firmware.
86 But this SoC shares spi and nand pins,
87 and current driver does't handle this sharing well */
88 status = "disabled";
89
90 m25p80@0 {
91 #address-cells = <1>;
92 #size-cells = <1>;
93 compatible = "jedec,spi-nor";
94 reg = <1>;
95 spi-max-frequency = <10000000>;
96 m25p,chunked-io = <32>;
97
98 partition@0 {
99 label = "spi";
100 reg = <0x0 0x200000>;
101 read-only;
102 };
103 };
104 };
105
106 &xhci {
107 status = "disabled";
108 };