realtek: pcs: rtl931x: drop USXGMII gating in setup_serdes

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>
This commit is contained in:
Jonas Jelonek 2026-04-23 11:28:45 +00:00 committed by Robert Marko
parent 9eb0edfe2b
commit b447bf5686

View 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);