Fresh pull from upstream lede-17.01 branch to fix several outstanding
[librecmc/librecmc.git] / target / linux / ramips / dts / ALL0256N-8M.dts
1 /dts-v1/;
2
3 #include "rt3050.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8         compatible = "ALL0256N", "ralink,rt3050-soc";
9         model = "Allnet ALL0256N (8M)";
10
11         gpio-leds {
12                 compatible = "gpio-leds";
13
14                 rssilow {
15                         label = "all0256n:green:rssilow";
16                         gpios = <&gpio0 14 1>;
17                 };
18
19                 rssimed {
20                         label = "all0256n:green:rssimed";
21                         gpios = <&gpio0 12 1>;
22                 };
23
24                 rssihigh {
25                         label = "all0256n:green:rssihigh";
26                         gpios = <&gpio0 13 1>;
27                 };
28         };
29
30         gpio-keys-polled {
31                 compatible = "gpio-keys-polled";
32                 #address-cells = <1>;
33                 #size-cells = <0>;
34                 poll-interval = <20>;
35
36                 reset {
37                         label = "reset";
38                         gpios = <&gpio0 0 1>;
39                         linux,code = <KEY_RESTART>;
40                 };
41         };
42 };
43
44 &gpio0 {
45         status = "okay";
46 };
47
48 &spi0 {
49         status = "okay";
50
51         m25p80@0 {
52                 #address-cells = <1>;
53                 #size-cells = <1>;
54                 compatible = "jedec,spi-nor";
55                 reg = <0>;
56                 spi-max-frequency = <10000000>;
57
58                 partition@0 {
59                         label = "u-boot";
60                         reg = <0x0 0x30000>;
61                         read-only;
62                 };
63
64                 partition@30000 {
65                         label = "u-boot-env";
66                         reg = <0x30000 0x10000>;
67                         read-only;
68                 };
69
70                 factory: partition@40000 {
71                         label = "factory";
72                         reg = <0x40000 0x10000>;
73                         read-only;
74                 };
75
76                 partition@50000 {
77                         label = "firmware";
78                         reg = <0x50000 0x7b0000>;
79                 };
80         };
81 };
82
83 &pinctrl {
84         state_default: pinctrl0 {
85                 gpio {
86                         ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
87                         ralink,function = "gpio";
88                 };
89         };
90 };
91
92 &ethernet {
93         mtd-mac-address = <&factory 0x28>;
94 };
95
96 &esw {
97         mediatek,portmap = <0x3f>;
98 };
99
100 &wmac {
101         ralink,mtd-eeprom = <&factory 0>;
102 };