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