mediatek: add support for Adtran SmartRG Bonanza Peak series
[openwrt/staging/dangole.git] / target / linux / mediatek / dts / mt7986a-smartrg-SDG-8614.dts
diff --git a/target/linux/mediatek/dts/mt7986a-smartrg-SDG-8614.dts b/target/linux/mediatek/dts/mt7986a-smartrg-SDG-8614.dts
new file mode 100644 (file)
index 0000000..73f8fd5
--- /dev/null
@@ -0,0 +1,105 @@
+// SPDX-License-Identifier: (GPL-2.0 OR MIT)
+/*
+ * Copyright (C) 2022 SmartRG Inc.
+ * Author: Chad Monroe <chad.monroe@smartrg.com>
+ */
+
+#include "mt7986a-smartrg-bonanza-peak.dtsi"
+
+/ {
+       model = "SmartRG SDG-8614";
+       compatible = "smartrg,sdg-8614", "mediatek,mt7986a";
+
+       leds {
+               mux_sel {
+                       default-state = "off";
+               };
+       };
+
+       /* SFP1 cage (WAN) */
+       i2c_sfp1: i2c-gpio-0 {
+               compatible = "i2c-gpio";
+               sda-gpios = <&pio 62 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
+               scl-gpios = <&pio 63 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
+               i2c-gpio,delay-us = <2>;
+               #address-cells = <1>;
+               #size-cells = <0>;
+       };
+
+       sfp1: sfp1 {
+               compatible = "sff,sfp";
+               i2c-bus = <&i2c_sfp1>;
+               los-gpios = <&pio 20 GPIO_ACTIVE_HIGH>;
+               mod-def0-gpios = <&pio 65 GPIO_ACTIVE_LOW>;
+               rate-select0-gpios = <&pio 9 GPIO_ACTIVE_HIGH>;
+               rate-select1-gpios = <&pio 28 GPIO_ACTIVE_HIGH>;
+               tx-disable-gpios = <&pio 64 GPIO_ACTIVE_HIGH>;
+               tx-fault-gpios = <&pio 7 GPIO_ACTIVE_HIGH>;
+               maximum-power-milliwatt = <3000>;
+       };
+};
+
+&gmac0 {
+       fixed-link {
+               speed = <2500>;
+               full-duplex;
+               pause;
+       };
+};
+
+&gmac1 {
+       sfp = <&sfp1>;
+       managed = "in-band-status";
+};
+
+&mdio {
+       switch: switch@0 {
+               compatible = "mediatek,mt7531";
+               reg = <31>;
+               reset-gpios = <&pio 5 GPIO_ACTIVE_HIGH>;
+
+               ports {
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+
+                       port@1 {
+                               reg = <1>;
+                               label = "lan3";
+                       };
+
+                       port@2 {
+                               reg = <2>;
+                               label = "lan2";
+                       };
+
+                       port@3 {
+                               reg = <3>;
+                               label = "lan1";
+                       };
+
+                       port5: port@5 {
+                               reg = <5>;
+                               label = "lan4";
+
+                               phy-mode = "2500base-x";
+                               phy-handle = <&phy5>;
+                       };
+
+                       port@6 {
+                               reg = <6>;
+                               ethernet = <&gmac0>;
+                               phy-mode = "2500base-x";
+
+                               fixed-link {
+                                       speed = <2500>;
+                                       full-duplex;
+                                       pause;
+                               };
+                       };
+               };
+       };
+};
+
+&wifi {
+       ieee80211-freq-limit = <2400000 2500000>, <5170000 5835000>;
+};