ath79: fix MAC address setup for TP-Link TL-WDR3600/TL-WDR4300
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar9331_tplink_tl-wr710n-v1.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 "ar9331.dtsi"
8
9 / {
10 model = "TP-Link TL-WR710N v1";
11 compatible = "tplink,tl-wr710n-v1", "qca,ar9331";
12
13 aliases {
14 serial0 = &uart;
15 led-boot = &led_system;
16 led-failsafe = &led_system;
17 led-running = &led_system;
18 led-upgrade = &led_system;
19 };
20
21 keys {
22 compatible = "gpio-keys-polled";
23 poll-interval = <20>;
24
25 reset {
26 label = "reset";
27 linux,code = <KEY_RESTART>;
28 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
29 debounce-interval = <60>;
30 };
31 };
32
33 leds {
34 compatible = "gpio-leds";
35
36 led_system: system {
37 label = "tl-wr710n:green:system";
38 gpios = <&gpio 27 GPIO_ACTIVE_LOW>;
39 };
40 };
41
42 reg_usb_vbus: regulator {
43 compatible = "regulator-fixed";
44 regulator-name = "usb_vbus";
45 regulator-min-microvolt = <5000000>;
46 regulator-max-microvolt = <5000000>;
47 gpio = <&gpio 8 GPIO_ACTIVE_HIGH>;
48 enable-active-high;
49 };
50
51 };
52
53 &spi {
54 status = "okay";
55 num-cs = <1>;
56
57 flash@0 {
58 compatible = "jedec,spi-nor";
59 reg = <0>;
60 spi-max-frequency = <25000000>;
61
62 partitions {
63 compatible = "fixed-partitions";
64 #address-cells = <1>;
65 #size-cells = <1>;
66
67 uboot: partition@0 {
68 reg = <0x0 0x20000>;
69 label = "u-boot";
70 read-only;
71 };
72
73 firmware: partition@20000 {
74 compatible = "tplink,firmware";
75 reg = <0x20000 0x7d0000>;
76 label = "firmware";
77 };
78
79 art: partition@7f0000 {
80 reg = <0x7f0000 0x10000>;
81 label = "art";
82 read-only;
83 };
84 };
85 };
86 };
87
88 &eth0 {
89 status = "okay";
90
91 mtd-mac-address = <&uboot 0x1fc00>;
92
93 gmac-config {
94 device = <&gmac>;
95
96 switch-phy-addr-swap = <0>;
97 switch-phy-swap = <0>;
98 };
99 };
100
101 &eth1 {
102 status = "okay";
103
104 mtd-mac-address = <&uboot 0x1fc00>;
105 mtd-mac-address-increment = <(-1)>;
106 };
107
108 &gpio {
109 status = "okay";
110 };
111
112 &uart {
113 status = "okay";
114 };
115
116 &usb {
117 dr_mode = "host";
118 vbus-supply = <&reg_usb_vbus>;
119 status = "okay";
120 };
121
122 &usb_phy {
123 status = "okay";
124 };
125
126 &wmac {
127 status = "okay";
128 mtd-cal-data = <&art 0x1000>;
129 mtd-mac-address = <&uboot 0x1fc00>;
130 };