Commit 98a6eeb8 authored by Nimrod Andy's avatar Nimrod Andy Committed by David S. Miller

net: fec: correct the MDIO clock source

Since imx serials FEC/ENET MDIO clock source is internal ipg clock,
and "ahb" clock is defined as FEC/ENET bus clock, so the patch just
correct the fec driver MDIO clock source.
Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
Acked-by: default avatarFrank Li <frank.li@freescale.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent e8fcfcd5
...@@ -1407,7 +1407,7 @@ static int fec_enet_mii_init(struct platform_device *pdev) ...@@ -1407,7 +1407,7 @@ static int fec_enet_mii_init(struct platform_device *pdev)
* Reference Manual has an error on this, and gets fixed on i.MX6Q * Reference Manual has an error on this, and gets fixed on i.MX6Q
* document. * document.
*/ */
fep->phy_speed = DIV_ROUND_UP(clk_get_rate(fep->clk_ahb), 5000000); fep->phy_speed = DIV_ROUND_UP(clk_get_rate(fep->clk_ipg), 5000000);
if (id_entry->driver_data & FEC_QUIRK_ENET_MAC) if (id_entry->driver_data & FEC_QUIRK_ENET_MAC)
fep->phy_speed--; fep->phy_speed--;
fep->phy_speed <<= 1; fep->phy_speed <<= 1;
......
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