Commit c9bca2fe authored by Xing Zheng's avatar Xing Zheng Committed by David S. Miller
Browse files

net: ethernet: arc: Probe emac after set RMII clock

After enter arc_emac_probe, emac will get_phy_id, phy_poll_reset and
other connecting PHY via mdiobus_read, so we need to set correct
ref clock rate for emac before probe emac.
Signed-off-by: default avatarXing Zheng <>
Signed-off-by: default avatarDavid S. Miller <>
parent 0652cb5b
......@@ -164,10 +164,6 @@ static int emac_rockchip_probe(struct platform_device *pdev)
err = arc_emac_probe(ndev, interface);
if (err)
goto out_regulator_disable;
/* write-enable bits */
......@@ -184,6 +180,13 @@ static int emac_rockchip_probe(struct platform_device *pdev)
err = clk_set_rate(priv->refclk, 50000000);
if (err)
dev_err(dev, "failed to change reference clock rate (%d)\n", err);
err = arc_emac_probe(ndev, interface);
if (err) {
dev_err(dev, "failed to probe arc emac (%d)\n", err);
goto out_regulator_disable;
return 0;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment