70b3ee68c3883758435f1844676952f2bcd0d535
[openwrt/openwrt.git] / target / linux / ath79 / dts / qca9558_mikrotik_routerboard-92x.dtsi
1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
2
3 #include "qca955x.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 aliases {
10 led-boot = &led_user;
11 led-failsafe = &led_user;
12 led-upgrade = &led_user;
13 serial0 = &uart;
14 };
15
16 leds {
17 compatible = "gpio-leds";
18
19 led_user: user {
20 label = "green:user";
21 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
22 };
23 };
24
25 keys {
26 compatible = "gpio-keys";
27
28 reset {
29 label = "reset";
30 linux,code = <KEY_RESTART>;
31 gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
32 debounce-interval = <60>;
33 };
34 };
35
36 gpio-export {
37 compatible = "gpio-export";
38
39 gpio_nand_power {
40 gpio-export,name = "mikrotik:power:nand";
41 gpio-export,output = <0>;
42 gpios = <&gpio 23 GPIO_ACTIVE_LOW>;
43 };
44 };
45 };
46
47 &mdio0 {
48 status = "okay";
49
50 phy4: ethernet-phy@4 {
51 reg = <4>;
52 };
53 };
54
55 &eth0 {
56 status = "okay";
57
58 phy-handle = <&phy4>;
59 pll-data = <0x8f000000 0xa0000101 0xa0001313>;
60
61 gmac-config {
62 device = <&gmac>;
63 rgmii-enabled = <1>;
64 };
65 };
66
67 &spi {
68 status = "okay";
69
70 flash@0 {
71 compatible = "jedec,spi-nor";
72 reg = <0>;
73 spi-max-frequency = <25000000>;
74
75 partitions {
76 compatible = "mikrotik,routerboot-partitions";
77 #address-cells = <1>;
78 #size-cells = <1>;
79
80 partition@0 {
81 label = "routerboot";
82 reg = <0x0 0x0>;
83 read-only;
84 };
85
86 hard_config: hard_config {
87 read-only;
88 };
89
90 bios {
91 size = <0x1000>;
92 read-only;
93 };
94
95 soft_config {
96 };
97 };
98 };
99 };
100
101 &nand {
102 status = "okay";
103
104 nand-ecc-mode = "soft";
105 qca,nand-swap-dma;
106 qca,nand-scan-fixup;
107
108 partitions {
109 compatible = "fixed-partitions";
110 #size-cells = <1>;
111
112 partition@0 {
113 label = "booter";
114 reg = <0x0000000 0x0040000>;
115 read-only;
116 };
117
118 partition@40000 {
119 label = "kernel";
120 reg = <0x0040000 0x03c0000>;
121 };
122
123 partition@400000 {
124 label = "ubi";
125 reg = <0x0400000 0x7c00000>;
126 };
127 };
128 };
129
130 &uart {
131 status = "okay";
132 };