fbc3acdd1b8b1eab542ebb8e86a856bce19fe399
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar9330_glinet_ar150.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2 /dts-v1/;
3
4 #include <dt-bindings/gpio/gpio.h>
5 #include <dt-bindings/input/input.h>
6
7 #include "ar9330.dtsi"
8
9 / {
10 model = "GL.iNet GL-AR150";
11 compatible = "glinet,ar150", "qca,ar9330";
12
13 aliases {
14 serial0 = &uart;
15 led-boot = &wlan;
16 led-failsafe = &wlan;
17 led-upgrade = &wlan;
18 };
19
20 leds {
21 compatible = "gpio-leds";
22
23 wlan: wlan {
24 label = "gl-ar150:orange:wlan";
25 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
26 linux,default-trigger = "phy0tpt";
27 };
28
29 lan {
30 label = "gl-ar150:green:lan";
31 gpios = <&gpio 13 GPIO_ACTIVE_HIGH>;
32 };
33
34 wan {
35 label = "gl-ar150:green:wan";
36 gpios = <&gpio 15 GPIO_ACTIVE_HIGH>;
37 };
38 };
39
40 keys {
41 compatible = "gpio-keys-polled";
42 poll-interval = <100>;
43
44 manual {
45 label = "manual";
46 linux,code = <BTN_7>;
47 gpios = <&gpio 7 GPIO_ACTIVE_HIGH>;
48 };
49
50 auto {
51 label = "auto";
52 linux,code = <BTN_8>;
53 gpios = <&gpio 8 GPIO_ACTIVE_HIGH>;
54 };
55
56 reset {
57 label = "reset";
58 linux,code = <KEY_RESTART>;
59 gpios = <&gpio 11 GPIO_ACTIVE_HIGH>;
60 };
61 };
62 };
63
64 &uart {
65 status = "okay";
66 };
67
68 &gpio {
69 status = "okay";
70 };
71
72 &usb {
73 dr_mode = "host";
74 status = "okay";
75 };
76
77 &usb_phy {
78 status = "okay";
79 gpios = <&gpio 6 GPIO_ACTIVE_HIGH>;
80 };
81
82 &spi {
83 num-chipselects = <1>;
84 status = "okay";
85
86 flash@0 {
87 compatible = "jedec,spi-nor";
88 spi-max-frequency = <104000000>;
89 reg = <0>;
90
91 partitions {
92 compatible = "fixed-partitions";
93 #address-cells = <1>;
94 #size-cells = <1>;
95
96 partition@0 {
97 label = "u-boot";
98 reg = <0x000000 0x040000>;
99 read-only;
100 };
101
102 partition@1 {
103 label = "u-boot-env";
104 reg = <0x040000 0x010000>;
105 };
106
107 partition@2 {
108 compatible = "denx,uimage";
109 label = "firmware";
110 reg = <0x050000 0xfa0000>;
111 };
112
113 art: partition@3 {
114 label = "ART";
115 reg = <0xff0000 0x010000>;
116 read-only;
117 };
118 };
119 };
120 };
121
122 &eth0 {
123 status = "okay";
124
125 mtd-mac-address = <&art 0x0>;
126 };
127
128 &eth1 {
129 status = "okay";
130
131 mtd-mac-address = <&art 0x0>;
132
133 gmac-config {
134 device = <&gmac>;
135
136 switch-phy-addr-swap = <0>;
137 switch-phy-swap = <0>;
138 };
139 };
140
141 &wmac {
142 status = "okay";
143 mtd-cal-data = <&art 0x1000>;
144 mtd-mac-address = <&art 0x0>;
145 };