OSDN Git Service

net: stmmac: dwmac-qcom-ethqos: Enable RGMII functional clock on resume
[uclinux-h8/linux.git] / drivers / net / ethernet / stmicro / stmmac / dwmac-qcom-ethqos.c
index 0cc28c7..835caa1 100644 (file)
@@ -487,6 +487,13 @@ static int ethqos_clks_config(void *priv, bool enabled)
                        dev_err(&ethqos->pdev->dev, "rgmii_clk enable failed\n");
                        return ret;
                }
+
+               /* Enable functional clock to prevent DMA reset to timeout due
+                * to lacking PHY clock after the hardware block has been power
+                * cycled. The actual configuration will be adjusted once
+                * ethqos_fix_mac_speed() is invoked.
+                */
+               ethqos_set_func_clk_en(ethqos);
        } else {
                clk_disable_unprepare(ethqos->rgmii_clk);
        }