ipq807x: sax1v1k: fix sysupgrade not touching rootfs_data
[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 };
14
15 leds {
16 compatible = "gpio-leds";
17
18 led_user: user {
19 label = "green:user";
20 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
21 };
22 };
23
24 keys {
25 compatible = "gpio-keys";
26
27 reset {
28 label = "reset";
29 linux,code = <KEY_RESTART>;
30 gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
31 debounce-interval = <60>;
32 };
33 };
34
35 gpio-export {
36 compatible = "gpio-export";
37
38 gpio_nand_power {
39 gpio-export,name = "mikrotik:power:nand";
40 gpio-export,output = <0>;
41 gpios = <&gpio 23 GPIO_ACTIVE_LOW>;
42 };
43 };
44
45 i2c: i2c {
46 compatible = "i2c-gpio";
47
48 sda-gpios = <&gpio 18 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
49 scl-gpios = <&gpio 19 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
50 i2c-gpio,delay-us = <5>;
51 i2c-gpio,timeout-ms = <1>;
52 };
53
54 sfp1: sfp {
55 compatible = "sff,sfp";
56
57 i2c-bus = <&i2c>;
58 maximum-power-milliwatt = <1000>;
59 los-gpios = <&gpio 21 GPIO_ACTIVE_HIGH>;
60 mod-def0-gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
61 tx-disable-gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
62 // Toggling GPIO16 actually enables/disables the transmitter,
63 // but the SFP driver does not seem to be using it.
64 };
65 };
66
67 &mdio0 {
68 status = "okay";
69
70 phy4: ethernet-phy@4 {
71 reg = <4>;
72 };
73 };
74
75 &eth0 {
76 status = "okay";
77
78 phy-handle = <&phy4>;
79 pll-data = <0x8f000000 0xa0000101 0xa0001313>;
80
81 gmac-config {
82 device = <&gmac>;
83 rgmii-enabled = <1>;
84 };
85 };
86
87 &mdio1 {
88 phy_sfp: ethernet-phy@0 {
89 reg = <0>;
90 phy-mode = "sgmii";
91 sfp = <&sfp1>;
92 };
93 };
94
95 &eth1 {
96 phy-handle = <&phy_sfp>;
97 pll-data = <0x03000000 0x00000101 0x00001616>;
98 qca955x-sgmii-fixup;
99
100 gmac-config {
101 device = <&gmac>;
102 };
103
104 fixed-link {
105 speed = <1000>;
106 full-duplex;
107 };
108 };
109
110 &spi {
111 status = "okay";
112
113 flash@0 {
114 compatible = "jedec,spi-nor";
115 reg = <0>;
116 spi-max-frequency = <25000000>;
117
118 partitions {
119 compatible = "mikrotik,routerboot-partitions";
120 #address-cells = <1>;
121 #size-cells = <1>;
122
123 partition@0 {
124 label = "routerboot";
125 reg = <0x0 0x0>;
126 read-only;
127 };
128
129 hard_config {
130 read-only;
131 };
132
133 bios {
134 size = <0x1000>;
135 read-only;
136 };
137
138 soft_config {
139 };
140 };
141 };
142 };
143
144 &nand {
145 status = "okay";
146
147 nand-ecc-mode = "soft";
148 nand-ecc-step-size = <2048>;
149 qca,nand-swap-dma;
150 qca,nand-scan-fixup;
151
152 partitions {
153 compatible = "fixed-partitions";
154 #address-cells = <1>;
155 #size-cells = <1>;
156
157 partition@0 {
158 label = "booter";
159 reg = <0x0000000 0x0040000>;
160 read-only;
161 };
162
163 partition@40000 {
164 label = "kernel";
165 reg = <0x0040000 0x03c0000>;
166 };
167
168 partition@400000 {
169 label = "ubi";
170 reg = <0x0400000 0x7c00000>;
171 };
172 };
173 };