Skip to content

Commit f8ba2d6

Browse files
mmindbebarino
authored andcommitted
clk: rockchip: Make uartpll a child of the gpll on rk3036
The shared uart-pll is on boot a child of the apll that can get changed by cpu frequency scaling. So move it away to the more stable gpll to make sure the uart doesn't break on cpu frequency changes. This turned up during the 4.11 merge-window when commit 6a171b2 ("serial: 8250_dw: Allow hardware flow control to be used") added general termios enablement making the uart on rk3036 change frequency and thus making it susceptible for the frequency scaling issue. Signed-off-by: Heiko Stuebner <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
1 parent 9b1b23f commit f8ba2d6

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/clk/rockchip/clk-rk3036.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -450,6 +450,13 @@ static void __init rk3036_clk_init(struct device_node *np)
450450
return;
451451
}
452452

453+
/*
454+
* Make uart_pll_clk a child of the gpll, as all other sources are
455+
* not that usable / stable.
456+
*/
457+
writel_relaxed(HIWORD_UPDATE(0x2, 0x3, 10),
458+
reg_base + RK2928_CLKSEL_CON(13));
459+
453460
ctx = rockchip_clk_init(np, reg_base, CLK_NR_CLKS);
454461
if (IS_ERR(ctx)) {
455462
pr_err("%s: rockchip clk init failed\n", __func__);

0 commit comments

Comments
 (0)