feae550039c09b38b995be13216f91438c11cc42
[oweals/openwrt.git] / target / linux / ath79 / dts / qca9556_mikrotik_routerboard-wap-g-5hact2hnd.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 "qca955x.dtsi"
8
9 / {
10         compatible = "mikrotik,routerboard-wap-g-5hact2hnd", "qca,qca9556";
11         model = "MikroTik RouterBOARD wAP G-5HacT2HnD";
12
13         aliases {
14                 mdio-gpio1 = &mdio2;
15                 serial0 = &uart;
16         };
17
18         chosen {
19                 bootargs = "console=ttyS0,115200n8";
20         };
21
22         keys {
23                 compatible = "gpio-keys";
24
25                 reset {
26                         label = "reset";
27                         linux,code = <KEY_RESTART>;
28                         gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
29                         debounce-interval = <60>;
30                 };
31         };
32
33         mdio2: mdio {
34                 compatible = "virtual,mdio-gpio";
35
36                 gpios = <&gpio 12 GPIO_ACTIVE_HIGH>, /* MDC */
37                         <&gpio 11 GPIO_ACTIVE_HIGH>; /* MDIO */
38                 #address-cells = <1>;
39                 #size-cells = <0>;
40
41                 phy0: ethernet-phy@0 {
42                         reg = <0>;
43                         device_type = "ethernet-phy";
44
45                         phy-mode = "sgmii";
46
47                         at803x-override-sgmii-link-check;
48                 };
49         };
50 };
51
52 &eth1 {
53         status = "okay";
54
55         pll-data = <0x03000101 0x80000101 0x80001313>;
56         phy-handle = <&phy0>;
57
58         qca955x-sgmii-fixup;
59
60         gmac-config {
61                 device = <&gmac>;
62         };
63 };
64
65 &spi {
66         status = "okay";
67
68         num-cs = <1>;
69
70         flash@0 {
71                 compatible = "jedec,spi-nor";
72                 reg = <0>;
73                 spi-max-frequency = <40000000>;
74
75                 partitions {
76                         compatible = "fixed-partitions";
77                         #address-cells = <1>;
78                         #size-cells = <1>;
79
80                         partition@0 {
81                                 label = "RouterBoot";
82                                 reg = <0x0 0x20000>;
83                                 read-only;
84                                 compatible = "mikrotik,routerboot-partitions";
85                                 #address-cells = <1>;
86                                 #size-cells = <1>;
87
88                                 partition@0 {
89                                         label = "bootloader1";
90                                         reg = <0x0 0x0>;
91                                         read-only;
92                                 };
93
94                                 hard_config: hard_config {
95                                         read-only;
96                                 };
97
98                                 bios {
99                                         size = <0x1000>;
100                                         read-only;
101                                 };
102
103                                 partition@10000 {
104                                         label = "bootloader2";
105                                         reg = <0x10000 0x0>;
106                                         read-only;
107                                 };
108
109                                 soft_config {
110                                         label = "soft_config";
111                                 };
112                         };
113
114                         partition@20000 {
115                                 compatible = "mikrotik,minor";
116                                 label = "firmware";
117                                 reg = <0x020000 0xfe0000>;
118                         };
119                 };
120         };
121 };
122
123 &uart {
124         status = "okay";
125 };
126
127 &wmac {
128         status = "okay";
129
130         qca,no-eeprom;
131 };
132
133 &pcie0 {
134         status = "okay";
135
136         wifi@0,0 {
137                 compatible = "qcom,ath10k";
138                 reg = <0 0 0 0 0>;
139         };
140 };