diff --git a/drivers/clk/qcom/clk-alpha-pll.c b/drivers/clk/qcom/clk-alpha-pll.c index 640a2663a975..3908e101d113 100644 --- a/drivers/clk/qcom/clk-alpha-pll.c +++ b/drivers/clk/qcom/clk-alpha-pll.c @@ -1593,6 +1593,20 @@ static int alpha_pll_lucid_prepare(struct clk_hw *hw) if (regval & LUCID_PCAL_DONE) return 0; + if (pll->config) { + /* + * Reconfigure the PLL if CAL_L_VAL is 0 (which implies that all + * clock controller registers have been reset). + */ + regmap_read(pll->clkr.regmap, PLL_CAL_L_VAL(pll), ®val); + if (!regval) { + pr_debug("reconfiguring %s after it was reset\n", + clk_hw_get_name(hw)); + clk_lucid_pll_configure(pll, pll->clkr.regmap, + pll->config); + } + } + p = clk_hw_get_parent(hw); if (!p) return -EINVAL;