net: mscc: ocelot: filter out ocelot SoC specific PCS config from common path
[linux-2.6-microblaze.git] / drivers / net / ethernet / mscc / ocelot.c
index 3e7a279..2b6792a 100644 (file)
@@ -455,23 +455,8 @@ static void ocelot_adjust_link(struct ocelot *ocelot, int port,
        ocelot_port_writel(ocelot_port, DEV_MAC_HDX_CFG_LATE_COL_POS(67),
                           DEV_MAC_HDX_CFG);
 
-       /* Disable HDX fast control */
-       ocelot_port_writel(ocelot_port, DEV_PORT_MISC_HDX_FAST_DIS,
-                          DEV_PORT_MISC);
-
-       /* SGMII only for now */
-       ocelot_port_writel(ocelot_port, PCS1G_MODE_CFG_SGMII_MODE_ENA,
-                          PCS1G_MODE_CFG);
-       ocelot_port_writel(ocelot_port, PCS1G_SD_CFG_SD_SEL, PCS1G_SD_CFG);
-
-       /* Enable PCS */
-       ocelot_port_writel(ocelot_port, PCS1G_CFG_PCS_ENA, PCS1G_CFG);
-
-       /* No aneg on SGMII */
-       ocelot_port_writel(ocelot_port, 0, PCS1G_ANEG_CFG);
-
-       /* No loopback */
-       ocelot_port_writel(ocelot_port, 0, PCS1G_LB_CFG);
+       if (ocelot->ops->pcs_init)
+               ocelot->ops->pcs_init(ocelot, port);
 
        /* Set Max Length and maximum tags allowed */
        ocelot_port_writel(ocelot_port, VLAN_ETH_FRAME_LEN,