bbc0f1c7113353cc1eb83cdf56efdae281068678
[openwrt/openwrt.git] / target / linux / ath79 / dts / ar9331_hak5_wifi-pineapple-nano.dts
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "ar9331.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 model = "Hak5 WiFi Pineapple NANO";
10 compatible = "hak5,wifi-pineapple-nano", "qca,ar9331";
11
12 aliases {
13 label-mac-device = &wmac;
14 led-boot = &led_system;
15 led-failsafe = &led_system;
16 led-upgrade = &led_system;
17 serial0 = &uart;
18 };
19
20 gpio-export {
21 compatible = "gpio-export";
22 #size-cells = <0>;
23
24 microsd-detect {
25 gpio-export,name = "microsd-detect";
26 gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
27 };
28
29 usb-alarm {
30 gpio-export,name = "usb-alarm";
31 gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
32 };
33
34 usb-power {
35 gpio-export,name = "usb-power";
36 gpio-export,output = <0>;
37 gpios = <&gpio 23 GPIO_ACTIVE_LOW>;
38 };
39 };
40
41 keys {
42 compatible = "gpio-keys";
43
44 reset {
45 label = "reset";
46 linux,code = <KEY_RESTART>;
47 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
48 debounce-interval = <60>;
49 };
50 };
51
52 leds {
53 compatible = "gpio-leds";
54
55 led_system: system {
56 label = "blue:system";
57 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
58 linux,default-trigger = "phy0tpt";
59 };
60 };
61 };
62
63 &eth0 {
64 status = "okay";
65
66 mtd-mac-address = <&art 0x6>;
67 };
68
69 &eth1 {
70 status = "okay";
71
72 compatible = "syscon", "simple-mfd";
73 };
74
75 &spi {
76 status = "okay";
77
78 flash@0 {
79 compatible = "jedec,spi-nor";
80 reg = <0>;
81 spi-max-frequency = <50000000>;
82 m25p,fast-read;
83
84 partitions {
85 compatible = "fixed-partitions";
86 #address-cells = <1>;
87 #size-cells = <1>;
88
89 partition@0 {
90 label = "u-boot";
91 reg = <0x000000 0x020000>;
92 read-only;
93 };
94
95 partition@20000 {
96 label = "firmware";
97 reg = <0x020000 0xfd0000>;
98 compatible = "tplink,firmware";
99 };
100
101 art: partition@ff0000 {
102 label = "art";
103 reg = <0xff0000 0x010000>;
104 read-only;
105 };
106 };
107 };
108 };
109
110 &uart {
111 status = "okay";
112 };
113
114 &usb {
115 status = "okay";
116 };
117
118 &usb_phy {
119 status = "okay";
120 };
121
122 &wmac {
123 status = "okay";
124
125 mtd-cal-data = <&art 0x1000>;
126 };