ramips: add support for TP-Link RE200 v1
[oweals/openwrt.git] / target / linux / ramips / dts / mt7621_asiarf_ap7621.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9         chosen {
10                 bootargs = "console=ttyS0,57600";
11         };
12
13         keys {
14                 compatible = "gpio-keys";
15
16                 reset {
17                         label = "reset";
18                         gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
19                         linux,code = <KEY_RESTART>;
20                 };
21         };
22
23         leds {
24                 compatible = "gpio-leds";
25
26                 wlan1 {
27                         label = "ap7621-001:orange:wlan1";
28                         gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
29                 };
30
31                 wlan0 {
32                         label = "ap7621-001:orange:wlan0";
33                         gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
34                 };
35         };
36 };
37
38 &sdhci {
39         status = "okay";
40 };
41
42 &spi0 {
43         status = "okay";
44
45         flash@0 {
46                 compatible = "jedec,spi-nor";
47                 reg = <0>;
48                 spi-max-frequency = <40000000>;
49
50                 partitions {
51                         compatible = "fixed-partitions";
52                         #address-cells = <1>;
53                         #size-cells = <1>;
54
55                         partition@0 {
56                                 label = "u-boot";
57                                 reg = <0x0 0x30000>;
58                                 read-only;
59                         };
60
61                         partition@30000 {
62                                 label = "u-boot-env";
63                                 reg = <0x30000 0x2000>;
64                         };
65
66                         partition@32000 {
67                                 label = "2860";
68                                 reg = <0x32000 0x4000>;
69                         };
70
71                         partition@36000 {
72                                 label = "rtdev";
73                                 reg = <0x36000 0x2000>;
74                         };
75
76                         partition@38000 {
77                                 label = "Reserve";
78                                 reg = <0x38000 0x8000>;
79                         };
80
81                         factory: partition@40000 {
82                                 label = "factory";
83                                 reg = <0x40000 0x10000>;
84                                 read-only;
85                         };
86
87                         partition@50000 {
88                                 label = "firmware";
89                                 reg = <0x50000 0xfa0000>;
90                                 compatible = "denx,uimage";
91                         };
92
93                         partition@ff0000 {
94                                 label = "nvram";
95                                 reg = <0xff0000 0x10000>;
96                                 read-only;
97                         };
98                 };
99         };
100 };
101
102 &pcie {
103         status = "okay";
104 };
105
106 &ethernet {
107         mtd-mac-address = <&factory 0xe000>;
108         mediatek,portmap = "llllw";
109 };
110
111 &state_default {
112         gpio {
113                 ralink,group = "wdt", "jtag";
114                 ralink,function = "gpio";
115         };
116 };