/* Configure the MDIO Clock 2.5 MHz */
        gswip_mdio_mask(priv, 0xff, 0x09, GSWIP_MDIO_MDC_CFG1);
 
-       /* Disable the xMII link */
-       for (i = 0; i < priv->hw_info->max_ports; i++)
+       for (i = 0; i < priv->hw_info->max_ports; i++) {
+               /* Disable the xMII link */
                gswip_mii_mask_cfg(priv, GSWIP_MII_CFG_EN, 0, i);
 
+               /* Automatically select the xMII interface clock */
+               gswip_mii_mask_cfg(priv, GSWIP_MII_CFG_RATE_MASK,
+                                  GSWIP_MII_CFG_RATE_AUTO, i);
+       }
+
        /* enable special tag insertion on cpu port */
        gswip_switch_mask(priv, 0, GSWIP_FDMA_PCTRL_STEN,
                          GSWIP_FDMA_PCTRLp(cpu_port));