projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
349959a
)
ASoC: tlv320aic32x4: add a check for devm_clk_get
author
Chuhong Yuan
<hslester96@gmail.com>
Fri, 18 Oct 2019 08:14:49 +0000
(16:14 +0800)
committer
Mark Brown
<broonie@kernel.org>
Fri, 18 Oct 2019 17:12:13 +0000
(18:12 +0100)
aic32x4_set_dai_sysclk misses a check for devm_clk_get and may miss the
failure.
Add a check to fix it.
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Link:
https://lore.kernel.org/r/20191018081448.8486-1-hslester96@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/tlv320aic32x4.c
patch
|
blob
|
history
diff --git
a/sound/soc/codecs/tlv320aic32x4.c
b/sound/soc/codecs/tlv320aic32x4.c
index
68165de
..
b4e9a6c
100644
(file)
--- a/
sound/soc/codecs/tlv320aic32x4.c
+++ b/
sound/soc/codecs/tlv320aic32x4.c
@@
-573,6
+573,9
@@
static int aic32x4_set_dai_sysclk(struct snd_soc_dai *codec_dai,
struct clk *pll;
pll = devm_clk_get(component->dev, "pll");
+ if (IS_ERR(pll))
+ return PTR_ERR(pll);
+
mclk = clk_get_parent(pll);
return clk_set_rate(mclk, freq);