net: phylink: disable BMCR_ISOLATE in phylink_mii_c22_pcs_config
authorRobert Hancock <robert.hancock@calian.com>
Mon, 26 Oct 2020 17:58:02 +0000 (11:58 -0600)
committerJakub Kicinski <kuba@kernel.org>
Wed, 28 Oct 2020 01:30:20 +0000 (18:30 -0700)
The Xilinx PCS/PMA PHY requires that BMCR_ISOLATE be disabled for proper
operation in 1000BaseX mode. It should be safe to ensure this bit is
disabled in phylink_mii_c22_pcs_config in all cases.

Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Reviewed-by: Russell King <rmk+kernel@armlinux.org.uk>
Link: https://lore.kernel.org/r/20201026175802.1332477-1-robert.hancock@calian.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/phy/phylink.c

index fe2296f..5d8c015 100644 (file)
@@ -2515,9 +2515,10 @@ int phylink_mii_c22_pcs_config(struct mdio_device *pcs, unsigned int mode,
 
        changed = ret > 0;
 
+       /* Ensure ISOLATE bit is disabled */
        bmcr = mode == MLO_AN_INBAND ? BMCR_ANENABLE : 0;
        ret = mdiobus_modify(pcs->bus, pcs->addr, MII_BMCR,
-                            BMCR_ANENABLE, bmcr);
+                            BMCR_ANENABLE | BMCR_ISOLATE, bmcr);
        if (ret < 0)
                return ret;