Commit f4ca7a92 authored by Biao Huang's avatar Biao Huang Committed by David S. Miller

net: stmmac: dwmac-mediatek: modify csr_clk value to fix mdio read/write fail

1. the frequency of csr clock is 66.5MHz, so the csr_clk value should
be 0 other than 5.
2. the csr_clk can be got from device tree, so remove initialization here.

Fixes: 9992f37e ("stmmac: dwmac-mediatek: add support for mt2712")
Signed-off-by: default avatarBiao Huang <biao.huang@mediatek.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5e7f7fc5
...@@ -346,8 +346,6 @@ static int mediatek_dwmac_probe(struct platform_device *pdev) ...@@ -346,8 +346,6 @@ static int mediatek_dwmac_probe(struct platform_device *pdev)
return PTR_ERR(plat_dat); return PTR_ERR(plat_dat);
plat_dat->interface = priv_plat->phy_mode; plat_dat->interface = priv_plat->phy_mode;
/* clk_csr_i = 250-300MHz & MDC = clk_csr_i/124 */
plat_dat->clk_csr = 5;
plat_dat->has_gmac4 = 1; plat_dat->has_gmac4 = 1;
plat_dat->has_gmac = 0; plat_dat->has_gmac = 0;
plat_dat->pmt = 0; plat_dat->pmt = 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