ath79: WNDR3700 v1/v2: make u-boot env partition writable
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9563_glinet_gl-ar750s.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 "qca956x.dtsi"
8
9 / {
10 compatible = "glinet,gl-ar750s", "qca,qca9563";
11 model = "GL.iNet GL-AR750S";
12
13 chosen {
14 bootargs = "console=ttyS0,115200n8";
15 };
16
17 aliases {
18 led-boot = &power;
19 led-failsafe = &power;
20 led-running = &power;
21 led-upgrade = &power;
22 };
23
24 keys {
25 compatible = "gpio-keys-polled";
26 poll-interval = <20>;
27 pinctrl-names = "default";
28 pinctrl-0 = <&jtag_disable_pins>;
29
30 reset {
31 label = "reset";
32 linux,code = <KEY_RESTART>;
33 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
34 };
35
36 mode {
37 label = "mode";
38 linux,code = <BTN_0>;
39 linux,input-type = <EV_SW>;
40 gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
41 };
42 };
43
44 leds {
45 compatible = "gpio-leds";
46
47 power: power {
48 label = "gl-ar750s:green:power";
49 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
50 default-state = "keep";
51 };
52
53 wlan2g {
54 label = "gl-ar750s:green:wlan2g";
55 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
56 linux,default-trigger = "phy1tpt";
57 };
58
59 wlan5g {
60 label = "gl-ar750s:green:wlan5g";
61 gpios = <&gpio 20 GPIO_ACTIVE_HIGH>;
62 linux,default-trigger = "phy0tpt";
63 };
64 };
65
66 usb_vbus: regulator-usb-vbus {
67 compatible = "regulator-fixed";
68
69 regulator-name = "USB_VBUS";
70
71 regulator-min-microvolt = <5000000>;
72 regulator-max-microvolt = <5000000>;
73 regulator-always-on;
74
75 gpio = <&gpio 7 GPIO_ACTIVE_HIGH>;
76 enable-active-high;
77 };
78 };
79
80 &spi {
81 status = "okay";
82 num-cs = <0>;
83
84 flash@0 {
85 compatible = "jedec,spi-nor";
86 reg = <0>;
87 spi-max-frequency = <25000000>;
88
89 partitions {
90 compatible = "fixed-partitions";
91 #address-cells = <1>;
92 #size-cells = <1>;
93
94 partition@0 {
95 label = "u-boot";
96 reg = <0x000000 0x040000>;
97 read-only;
98 };
99
100 partition@40000 {
101 label = "u-boot-env";
102 reg = <0x040000 0x010000>;
103 };
104
105 art: partition@50000 {
106 label = "art";
107 reg = <0x050000 0x010000>;
108 read-only;
109 };
110
111 partition@60000 {
112 compatible = "denx,uimage";
113 label = "firmware";
114 reg = <0x060000 0xfa0000>;
115 };
116 };
117 };
118 };
119
120 &pcie {
121 status = "okay";
122 };
123
124 &uart {
125 status = "okay";
126 };
127
128 &usb0 {
129 status = "okay";
130 vbus-supply = <&usb_vbus>;
131 };
132
133 &usb_phy0 {
134 status = "okay";
135 };
136
137 &usb1 {
138 status = "okay";
139 };
140
141 &usb_phy1 {
142 status = "okay";
143 };
144
145 &mdio0 {
146 status = "okay";
147 phy-mask = <0>;
148
149 phy0: ethernet-phy@0 {
150 reg = <0>;
151 phy-mode = "sgmii";
152 qca,ar8327-initvals = <
153 0x04 0x00080080 /* PORT0 PAD MODE CTRL */
154 0x7c 0x0000007e /* PORT0_STATUS */
155 >;
156 };
157 };
158
159 &eth0 {
160 status = "okay";
161
162 mtd-mac-address = <&art 0x0>;
163 phy-handle = <&phy0>;
164 };
165
166 &wmac {
167 status = "okay";
168 mtd-cal-data = <&art 0x1000>;
169 mtd-mac-address = <&art 0x1002>;
170 };