From: Aravind Anilraj <aravindanilraj0702@gmail.com>
If byt_rt5640_prepare_and_enable_pll1() fails, the function returns
without calling clk_disable_unprepare() on priv->mclk, which was already
enabled earlier in the same code path. Add the missing
clk_disable_unprepare() call before returning the error
Signed-off-by: Aravind Anilraj <aravindanilraj0702@gmail.com>
---
sound/soc/intel/boards/bytcr_rt5640.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/sound/soc/intel/boards/bytcr_rt5640.c b/sound/soc/intel/boards/bytcr_rt5640.c
index 103e0b445603..3ecfba161e56 100644
--- a/sound/soc/intel/boards/bytcr_rt5640.c
+++ b/sound/soc/intel/boards/bytcr_rt5640.c
@@ -304,6 +304,7 @@ static int platform_clock_control(struct snd_soc_dapm_widget *w,
if (ret < 0) {
dev_err(card->dev, "can't set codec sysclk: %d\n", ret);
+ clk_disable_unprepare(priv->mclk);
return ret;
}
--
2.47.3