ath79: enable gpio on ar933x by default
[openwrt/staging/chunkeey.git] / target / linux / ath79 / dts / ar9331_embeddedwireless_dorin.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 = "Embedded Wireless Dorin";
11 compatible = "embeddedwireless,dorin", "qca,ar9331";
12
13 aliases {
14 led-boot = &led_status;
15 led-failsafe = &led_status;
16 led-running = &led_status;
17 led-upgrade = &led_status;
18 serial0 = &uart;
19 };
20
21 leds {
22 compatible = "gpio-leds";
23
24 led_status: status {
25 label = "dorin:green:status";
26 gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
27 };
28 };
29
30 keys {
31 compatible = "gpio-keys";
32
33 wps {
34 label = "wps";
35 linux,code = <KEY_WPS_BUTTON>;
36 gpios = <&gpio 11 GPIO_ACTIVE_HIGH>;
37 };
38
39 reset {
40 label = "reset";
41 linux,code = <KEY_RESTART>;
42 gpios = <&gpio 6 GPIO_ACTIVE_HIGH>;
43 };
44 };
45 };
46
47 &uart {
48 status = "okay";
49 };
50
51 &usb {
52 dr_mode = "host";
53 status = "okay";
54 };
55
56 &usb_phy {
57 status = "okay";
58 };
59
60 &spi {
61 status = "okay";
62
63 num-chipselects = <1>;
64
65 flash@0 {
66 compatible = "jedec,spi-nor";
67 spi-max-frequency = <50000000>;
68 reg = <0>;
69
70 partitions {
71 compatible = "fixed-partitions";
72 #address-cells = <1>;
73 #size-cells = <1>;
74
75 partition@0 {
76 label = "u-boot";
77 reg = <0x000000 0x040000>;
78 read-only;
79 };
80
81 partition@1 {
82 label = "u-boot-env";
83 reg = <0x040000 0x010000>;
84 };
85
86 partition@2 {
87 compatible = "denx,uimage";
88 label = "firmware";
89 reg = <0x050000 0xfa0000>;
90 };
91
92 art: partition@3 {
93 label = "art";
94 reg = <0xff0000 0x010000>;
95 read-only;
96 };
97 };
98 };
99 };
100
101 &eth1 {
102 status = "okay";
103
104 mtd-mac-address = <&art 0x1002>;
105 mtd-mac-address-increment-byte = <3>;
106 mtd-mac-address-increment = <0x40>;
107 };
108
109 &mdio1 {
110 status = "okay";
111 };
112
113 &wmac {
114 status = "okay";
115
116 mtd-cal-data = <&art 0x1000>;
117 };