clk: rockchip: clk-cpu: fix up the pre_mux setting order

Fixes: 655309b7b3 ("clk: rockchip: clk-cpu: add mux setting for cpu
change frequency")
Change-Id: Id281b0d4f874f83e61f4da898fa648cd1dbb0e9a
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
This commit is contained in:
Elaine Zhang 2020-11-23 15:59:09 +08:00 committed by Tao Huang
parent 867c13c248
commit 6ac3d6c34f

View File

@ -217,14 +217,14 @@ static int rockchip_cpuclk_pre_rate_change(struct rockchip_cpuclk *cpuclk,
}
rockchip_boost_add_core_div(cpuclk->pll_hw, alt_prate);
rockchip_cpuclk_set_pre_muxs(cpuclk, rate);
/* select alternate parent */
writel(HIWORD_UPDATE(reg_data->mux_core_alt,
reg_data->mux_core_mask,
reg_data->mux_core_shift),
cpuclk->reg_base + reg_data->core_reg);
rockchip_cpuclk_set_pre_muxs(cpuclk, rate);
spin_unlock_irqrestore(cpuclk->lock, flags);
return 0;
}