ath79: ar: convert to mac-base
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar7242_buffalo_wzr-bhr.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar7242.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_diag;
11 led-failsafe = &led_diag;
12 led-upgrade = &led_diag;
13 };
14
15 keys: keys {
16 compatible = "gpio-keys";
17
18 usb {
19 label = "usb";
20 linux,code = <BTN_2>;
21 gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
22 debounce-interval = <60>;
23 };
24
25 reset {
26 label = "reset";
27 linux,code = <KEY_RESTART>;
28 gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
29 debounce-interval = <60>;
30 };
31 };
32
33 leds: leds {
34 compatible = "gpio-leds";
35
36 led_diag: diag {
37 label = "red:diag";
38 gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
39 };
40
41 usb {
42 label = "green:usb";
43 gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
44 trigger-sources = <&hub_port>;
45 linux,default-trigger = "usbport";
46 };
47 };
48
49 gpio-export {
50 compatible = "gpio-export";
51 #size-cells = <0>;
52
53 gpio_usb_power {
54 gpio-export,name = "buffalo:usb-power";
55 gpio-export,output = <1>;
56 gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
57 };
58 };
59
60 virtual_flash {
61 compatible = "mtd-concat";
62 devices = <&flash0 &flash1>;
63
64 partitions {
65 compatible = "fixed-partitions";
66 #address-cells = <1>;
67 #size-cells = <1>;
68
69 partition@0 {
70 reg = <0x0 0x40000>;
71 label = "u-boot";
72 read-only;
73 };
74
75 partition@40000 {
76 reg = <0x40000 0x10000>;
77 label = "u-boot-env";
78 };
79
80 art: partition@50000 {
81 reg = <0x50000 0x10000>;
82 label = "art";
83 read-only;
84 };
85
86 partition@60000 {
87 compatible = "denx,uimage";
88 reg = <0x60000 0x1f80000>;
89 label = "firmware";
90 };
91
92 partition@1fe0000 {
93 reg = <0x1fe0000 0x20000>;
94 label = "user_property";
95 read-only;
96 };
97 };
98 };
99 };
100
101 &spi {
102 status = "okay";
103
104 flash0: flash@0 {
105 compatible = "jedec,spi-nor";
106 reg = <0>;
107 spi-max-frequency = <25000000>;
108 };
109
110 flash1: flash@1 {
111 compatible = "jedec,spi-nor";
112 reg = <1>;
113 spi-max-frequency = <25000000>;
114 };
115 };
116
117 &mdio0 {
118 status = "okay";
119
120 phy0: ethernet-phy@0 {
121 reg = <0>;
122 phy-mode = "rgmii";
123 };
124 };
125
126 &eth0 {
127 status = "okay";
128
129 phy-mode = "rgmii";
130 phy-handle = <&phy0>;
131 };
132
133 &usb_phy {
134 status = "okay";
135 };
136
137 &usb {
138 status = "okay";
139 };