acf3501f90365991f150e7ed555102208ef82572
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7620n_zbtlink_zbt-we2026.dts
1 #include "mt7620n.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "zbtlink,zbt-we2026", "ralink,mt7620n-soc";
8 model = "Zbtlink ZBT-WE2026";
9
10 aliases {
11 led-boot = &led_power;
12 led-failsafe = &led_power;
13 led-running = &led_power;
14 led-upgrade = &led_power;
15 };
16
17 chosen {
18 bootargs = "console=ttyS0,115200";
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 led_power: power {
25 label = "red:power";
26 gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
27 };
28
29 wlan {
30 label = "green:wlan";
31 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
32 };
33 };
34
35 keys {
36 compatible = "gpio-keys";
37
38 reset {
39 label = "reset";
40 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
41 linux,code = <KEY_RESTART>;
42 };
43 };
44 };
45
46 &gpio1 {
47 status = "okay";
48 };
49
50 &gpio3 {
51 status = "okay";
52 };
53
54 &spi0 {
55 status = "okay";
56
57 flash@0 {
58 compatible = "jedec,spi-nor";
59 reg = <0>;
60 spi-max-frequency = <10000000>;
61
62 partitions {
63 compatible = "fixed-partitions";
64 #address-cells = <1>;
65 #size-cells = <1>;
66
67 partition@0 {
68 label = "u-boot";
69 reg = <0x0 0x30000>;
70 read-only;
71 };
72
73 partition@30000 {
74 label = "u-boot-env";
75 reg = <0x30000 0x10000>;
76 read-only;
77 };
78
79 factory: partition@40000 {
80 compatible = "nvmem-cells";
81 label = "factory";
82 reg = <0x40000 0x10000>;
83 #address-cells = <1>;
84 #size-cells = <1>;
85 read-only;
86
87 eeprom_factory_0: eeprom@0 {
88 reg = <0x0 0x200>;
89 };
90
91 macaddr_factory_4: macaddr@4 {
92 reg = <0x4 0x6>;
93 };
94 };
95
96 partition@50000 {
97 compatible = "denx,uimage";
98 label = "firmware";
99 reg = <0x50000 0x760000>;
100 };
101 };
102 };
103 };
104
105 &ethernet {
106 nvmem-cells = <&macaddr_factory_4>;
107 nvmem-cell-names = "mac-address";
108
109 mediatek,portmap = "llllw";
110 };
111
112 &wmac {
113 nvmem-cells = <&eeprom_factory_0>;
114 nvmem-cell-names = "eeprom";
115 };
116
117 &state_default {
118 default {
119 groups = "i2c", "spi refclk", "wled";
120 function = "gpio";
121 };
122 };