]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
realtek: pcs: rtl931x: drop USXGMII gating in setup_serdes 23120/head
authorJonas Jelonek <jelonek.jonas@gmail.com>
Thu, 23 Apr 2026 11:28:45 +0000 (11:28 +0000)
committerRobert Marko <robimarko@gmail.com>
Mon, 27 Apr 2026 11:47:18 +0000 (13:47 +0200)
The USXGMII_10GDXGMII and USXGMII_10GQXGMII early-return was added
when the submode register was not yet programmed, making those modes
effectively unconfigurable. With the submode now wired up at probe
time and written from the set_mode path, the gating is no longer
needed.

Keep the XSGMII gate - RTL8218D/E bring-up through the proprietary
10G SGMII path is still unimplemented - and rewrite the surrounding
comment accordingly.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23120
Signed-off-by: Robert Marko <robimarko@gmail.com>
target/linux/realtek/files-6.18/drivers/net/pcs/pcs-rtl-otto.c

index 93b26071cef1fcb10d2228a321abe867ee836b66..7a8020de73093672c0c4dc559667d5c188bced28 100644 (file)
@@ -3832,18 +3832,10 @@ static int rtpcs_931x_setup_serdes(struct rtpcs_serdes *sds,
        int ret;
 
        /*
-        * TODO: USXGMII is currently the swiss army knife to declare 10G
-        * multi port PHYs. Real devices use other modes instead. Especially
-        *
-        * - RTL8224 is driven in 10G_QXGMII
-        * - RTL8218D/E are driven in (Realtek proprietary) XSGMII (10G SGMII)
-        *
-        * For now, disable "USXGMII" modes we cannot configure properly. Only
-        * USXGMII_10GSXGMII is configured properly for now.
+        * TODO: XSGMII (Realtek-proprietary 10G SGMII used by RTL8218D/E)
+        * bring-up is not implemented yet.
         */
-       if (hw_mode == RTPCS_SDS_MODE_USXGMII_10GDXGMII ||
-           hw_mode == RTPCS_SDS_MODE_USXGMII_10GQXGMII ||
-           hw_mode == RTPCS_SDS_MODE_XSGMII)
+       if (hw_mode == RTPCS_SDS_MODE_XSGMII)
                return 0;
 
        val = rtpcs_sds_read_bits(sds, 0x1F, 0x9, 11, 6);