summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonas Jelonek2025-12-20 21:09:52 +0000
committerRobert Marko2025-12-29 16:06:19 +0000
commit75493a812fd5dbbd1839ecec3543cdc9ee7c3cca (patch)
tree2d1c82aae3151a57fdff8b8ac909972fc77b12a4
parent65dc1ecf49fbb426d2875263a3ac50eb44d3e172 (diff)
downloadopenwrt-75493a812fd5dbbd1839ecec3543cdc9ee7c3cca.tar.gz
realtek: pcs: rtl931x: merge and drop unused helper
Merge the unused helper 'rtpcs_931x_sds_fiber_disable' into Fiber mode setting, and drop the helper itself. As with the MII helper in a previous commit, functionality is basically the same just with a value for OFF mode. If functionality is required later, Fiber mode setting can be used with the OFF mode instead of carrying the unused helper until it's used. Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com> Link: https://github.com/openwrt/openwrt/pull/20736 Signed-off-by: Robert Marko <robimarko@gmail.com>
-rw-r--r--target/linux/realtek/files-6.12/drivers/net/pcs/pcs-rtl-otto.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/target/linux/realtek/files-6.12/drivers/net/pcs/pcs-rtl-otto.c b/target/linux/realtek/files-6.12/drivers/net/pcs/pcs-rtl-otto.c
index 91bcc6f392..2b737bc35b 100644
--- a/target/linux/realtek/files-6.12/drivers/net/pcs/pcs-rtl-otto.c
+++ b/target/linux/realtek/files-6.12/drivers/net/pcs/pcs-rtl-otto.c
@@ -2424,6 +2424,10 @@ static void rtpcs_931x_sds_fiber_mode_set(struct rtpcs_serdes *sds,
rtpcs_931x_sds_mii_mode_set(sds, RTPCS_SDS_MODE_OFF);
switch (hw_mode) {
+ case RTPCS_SDS_MODE_OFF:
+ val = 0x3f;
+ break;
+
case RTPCS_SDS_MODE_SGMII:
val = 0x5;
break;
@@ -2494,14 +2498,6 @@ static void rtpcs_931x_sds_rx_reset(struct rtpcs_serdes *sds)
mdelay(50);
}
-__always_unused
-static void rtpcs_931x_sds_fiber_disable(struct rtpcs_serdes *sds)
-{
- u32 v = 0x3F;
-
- rtpcs_sds_write_bits(sds, 0x1F, 0x9, 11, 6, v);
-}
-
static int rtpcs_931x_sds_cmu_page_get(phy_interface_t mode)
{
switch (mode) {