ath79: Define firmware partition format to all boards where applicable
[oweals/openwrt.git] / target / linux / ath79 / dts / ar7240_netgear_wnr612-v2.dtsi
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 "ar7240.dtsi"
8
9 / {
10         compatible = "netgear,wnr612-v2", "qca,ar7240";
11         model = "Netgear WNR612 V2";
12
13         aliases {
14                 led-boot = &power;
15                 led-failsafe = &power;
16                 led-running = &power;
17                 led-upgrade = &power;
18         };
19
20         gpio-keys-polled {
21                 compatible = "gpio-keys-polled";
22                 poll-interval = <20>;
23
24                 reset {
25                         label = "reset";
26                         linux,code = <KEY_RESTART>;
27                         gpios = <&ath9k 7 GPIO_ACTIVE_LOW>;
28                         debounce-interval = <60>;
29                 };
30         };
31
32         gpio-leds {
33                 compatible = "gpio-leds";
34                 power: power {
35                         label = "netgear:green:power";
36                         gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
37                 };
38
39                 lan1 {
40                         label = "netgear:green:lan1";
41                         gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
42                 };
43
44                 lan2 {
45                         label = "netgear:green:lan2";
46                         gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
47                 };
48
49                 wan {
50                         label = "netgear:green:wan";
51                         gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
52                 };
53
54                 wlan: wlan {
55                         label = "netgear:green:wlan";
56                         gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
57                         default-state = "off";
58                         linux,default-trigger = "phy0tpt";
59                 };
60         };
61 };
62
63 &spi {
64         status = "okay";
65         num-cs = <1>;
66
67         flash@0 {
68                 compatible = "jedec,spi-nor";
69                 reg = <0>;
70                 spi-max-frequency = <25000000>;
71
72                 partitions {
73                         compatible = "fixed-partitions";
74                         #address-cells = <1>;
75                         #size-cells = <1>;
76
77                         uboot: partition@0 {
78                                 reg = <0x0 0x40000>;
79                                 label = "u-boot";
80                                 read-only;
81                         };
82
83                         partition@40000 {
84                                 reg = <0x40000 0x10000>;
85                                 label = "u-boot-env";
86                         };
87
88                         partition@50000 {
89                                 compatible = "netgear,uimage";
90                                 reg = <0x50000 0x3a0000>;
91                                 label = "firmware";
92                         };
93
94                         partition@3f0000 {
95                                 reg = <0x3f0000 0x10000>;
96                                 label = "art";
97                                 read-only;
98                         };
99                 };
100         };
101 };
102
103 &eth0 {
104         status = "okay";
105
106         mtd-mac-address = <&uboot 0x1fc00>;
107         mtd-mac-address-increment = <(-1)>;
108 };
109
110 &eth1 {
111         status = "okay";
112
113         mtd-mac-address = <&uboot 0x1fc00>;
114         mtd-mac-address-increment = <1>;
115 };
116
117 &pcie {
118         status = "okay";
119
120         ath9k: wifi@0,0 {
121                 compatible = "pci168c,002b";
122                 reg = <0x0000 0 0 0 0>;
123                 qca,no-eeprom;
124                 #gpio-cells = <2>;
125                 gpio-controller;
126         };
127 };
128
129 &uart {
130         status = "okay";
131 };