提交 837f036c 编写于 作者: G Gabor Juhos 提交者: Ralf Baechle

MIPS: ath79: Use local ref clock rate in ar934x_get_pll_freq

The reference clock rate is passed in the first
argument of the function. Use that instead of the
rate of the global ath79_ref_clk variable.
Signed-off-by: NGabor Juhos <juhosg@openwrt.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/5779/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
上级 a1191927
......@@ -174,12 +174,12 @@ static u32 __init ar934x_get_pll_freq(u32 ref, u32 ref_div, u32 nint, u32 nfrac,
u64 t;
u32 ret;
t = ath79_ref_clk.rate;
t = ref;
t *= nint;
do_div(t, ref_div);
ret = t;
t = ath79_ref_clk.rate;
t = ref;
t *= nfrac;
do_div(t, ref_div * frac);
ret += t;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册