aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--package/boot/uboot-envtools/files/realtek1
-rw-r--r--target/linux/realtek/base-files/etc/board.d/02_network1
-rw-r--r--target/linux/realtek/base-files/lib/upgrade/platform.sh3
-rw-r--r--target/linux/realtek/dts-5.10/rtl8380_tplink_sg2008p-v1.dts20
-rw-r--r--target/linux/realtek/dts-5.10/rtl8380_tplink_sg2210p-v3.dts16
-rw-r--r--target/linux/realtek/dts-5.10/rtl8380_tplink_sg2xxx.dtsi14
-rw-r--r--target/linux/realtek/image/rtl838x.mk11
7 files changed, 64 insertions, 2 deletions
diff --git a/package/boot/uboot-envtools/files/realtek b/package/boot/uboot-envtools/files/realtek
index 22568afd12..f191503876 100644
--- a/package/boot/uboot-envtools/files/realtek
+++ b/package/boot/uboot-envtools/files/realtek
@@ -30,6 +30,7 @@ zyxel,gs1900-24hp-v2)
ubootenv_add_uci_sys_config "/dev/mtd$idx2" "0x0" "0x1000" "0x10000"
;;
tplink,sg2008p-v1|\
+tplink,sg2210p-v3|\
tplink,sg2452p-v4)
idx="$(find_mtd_index u-boot-env)"
[ -n "$idx" ] && \
diff --git a/target/linux/realtek/base-files/etc/board.d/02_network b/target/linux/realtek/base-files/etc/board.d/02_network
index aacbef77b4..1dea2ad5a6 100644
--- a/target/linux/realtek/base-files/etc/board.d/02_network
+++ b/target/linux/realtek/base-files/etc/board.d/02_network
@@ -40,6 +40,7 @@ hpe,1920-24g)
lan_mac_end=$(macaddr_add $lan_mac $((mac_count2-mac_count1)))
;;
tplink,sg2008p-v1|\
+tplink,sg2210p-v3|\
tplink,sg2452p-v4)
label_mac=$(get_mac_label)
lan_mac="$label_mac"
diff --git a/target/linux/realtek/base-files/lib/upgrade/platform.sh b/target/linux/realtek/base-files/lib/upgrade/platform.sh
index b39b332063..6faded74b5 100644
--- a/target/linux/realtek/base-files/lib/upgrade/platform.sh
+++ b/target/linux/realtek/base-files/lib/upgrade/platform.sh
@@ -27,7 +27,8 @@ platform_do_upgrade() {
local board=$(board_name)
case "$board" in
- tplink,sg2008p-v1)
+ tplink,sg2008p-v1|\
+ tplink,sg2210p-v3)
tplink_sg2xxx_fix_mtdparts
default_do_upgrade "$1"
;;
diff --git a/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2008p-v1.dts b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2008p-v1.dts
index 0fef52984c..bf43e412b1 100644
--- a/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2008p-v1.dts
+++ b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2008p-v1.dts
@@ -6,3 +6,23 @@
compatible = "tplink,sg2008p-v1", "realtek,rtl838x-soc";
model = "TP-Link SG2008P v1";
};
+
+&tps23861_20 {
+ status = "disabled";
+};
+
+&phy24 {
+ status = "disabled";
+};
+
+&phy26 {
+ status = "disabled";
+};
+
+&port24 {
+ status = "disabled";
+};
+
+&port26 {
+ status = "disabled";
+};
diff --git a/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2210p-v3.dts b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2210p-v3.dts
new file mode 100644
index 0000000000..4b0022c388
--- /dev/null
+++ b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2210p-v3.dts
@@ -0,0 +1,16 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+#include "rtl8380_tplink_sg2xxx.dtsi"
+
+/ {
+ compatible = "tplink,sg2210p-v3", "realtek,rtl838x-soc";
+ model = "TP-Link SG2210P v3";
+};
+
+&port24 {
+ label = "lan-sfp2";
+};
+
+&port26 {
+ label = "lan-sfp1";
+};
diff --git a/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2xxx.dtsi b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2xxx.dtsi
index 8eb309d8a8..e727a9405a 100644
--- a/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2xxx.dtsi
+++ b/target/linux/realtek/dts-5.10/rtl8380_tplink_sg2xxx.dtsi
@@ -51,7 +51,13 @@
#address-cells = <1>;
#size-cells = <0>;
- tps23861@28 {
+ tps23861_20: tps23861@20 {
+ compatible = "ti,tps23861";
+ reg = <0x20>;
+ shunt-resistor-micro-ohms = <255000>;
+ };
+
+ tps23861_28: tps23861@28 {
compatible = "ti,tps23861";
reg = <0x28>;
shunt-resistor-micro-ohms = <255000>;
@@ -140,6 +146,9 @@
INTERNAL_PHY(13)
INTERNAL_PHY(14)
INTERNAL_PHY(15)
+
+ INTERNAL_PHY(24)
+ INTERNAL_PHY(26)
};
};
@@ -157,6 +166,9 @@
SWITCH_PORT(9, 7, internal)
SWITCH_PORT(8, 8, internal)
+ SWITCH_SFP_PORT(24, 9, 1000base-x)
+ SWITCH_SFP_PORT(26, 10, 1000base-x)
+
port@28 {
ethernet = <&ethernet0>;
reg = <28>;
diff --git a/target/linux/realtek/image/rtl838x.mk b/target/linux/realtek/image/rtl838x.mk
index 3e27576bda..36b19b3cbb 100644
--- a/target/linux/realtek/image/rtl838x.mk
+++ b/target/linux/realtek/image/rtl838x.mk
@@ -188,6 +188,17 @@ define Device/tplink_sg2008p-v1
endef
TARGET_DEVICES += tplink_sg2008p-v1
+define Device/tplink_sg2210p-v3
+ SOC := rtl8380
+ KERNEL_SIZE := 6m
+ IMAGE_SIZE := 26m
+ DEVICE_VENDOR := TP-Link
+ DEVICE_MODEL := SG2210P
+ DEVICE_VARIANT := v3
+ DEVICE_PACKAGES := kmod-hwmon-tps23861
+endef
+TARGET_DEVICES += tplink_sg2210p-v3
+
define Device/zyxel_gs1900
SOC := rtl8380
IMAGE_SIZE := 6976k