Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

phy: ti: gmii-sel: Add support for SGMII mode

Add support to configure the CPSW MAC's PHY in SGMII mode if the SoC
supports it. The extra_modes member of the phy_gmii_sel_soc_data struct
corresponding to the SoC is used to determine whether or not the SoC
supports SGMII mode.

Signed-off-by: Siddharth Vadapalli <s-vadapalli@ti.com>
Reviewed-by: Roger Quadros <rogerq@kernel.org>
Link: https://lore.kernel.org/r/20230309063514.398705-2-s-vadapalli@ti.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Siddharth Vadapalli and committed by
Vinod Koul
6a301188 1541fbac

+8
+8
drivers/phy/ti/phy-gmii-sel.c
··· 23 23 #define AM33XX_GMII_SEL_MODE_RGMII 2 24 24 25 25 /* J72xx SoC specific definitions for the CONTROL port */ 26 + #define J72XX_GMII_SEL_MODE_SGMII 3 26 27 #define J72XX_GMII_SEL_MODE_QSGMII 4 27 28 #define J72XX_GMII_SEL_MODE_QSGMII_SUB 6 28 29 ··· 105 104 gmii_sel_mode = J72XX_GMII_SEL_MODE_QSGMII; 106 105 else 107 106 gmii_sel_mode = J72XX_GMII_SEL_MODE_QSGMII_SUB; 107 + break; 108 + 109 + case PHY_INTERFACE_MODE_SGMII: 110 + if (!(soc_data->extra_modes & BIT(PHY_INTERFACE_MODE_SGMII))) 111 + goto unsupported; 112 + else 113 + gmii_sel_mode = J72XX_GMII_SEL_MODE_SGMII; 108 114 break; 109 115 110 116 default: