projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a754ea0
)
ASoC: mxs-saif: Handle errors for clk_enable
author
Jiasheng Jiang
<jiasheng@iscas.ac.cn>
Tue, 1 Mar 2022 08:17:17 +0000
(16:17 +0800)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 12:40:08 +0000
(14:40 +0200)
[ Upstream commit
2ecf362d220317debf5da376e0390e9f7a3f7b29
]
As the potential failure of the clk_enable(),
it should be better to check it, like mxs_saif_trigger().
Fixes:
d0ba4c014934
("ASoC: mxs-saif: set a base clock rate for EXTMASTER mode work")
Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Link:
https://lore.kernel.org/r/20220301081717.3727190-1-jiasheng@iscas.ac.cn
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
sound/soc/mxs/mxs-saif.c
patch
|
blob
|
blame
|
history
diff --git
a/sound/soc/mxs/mxs-saif.c
b/sound/soc/mxs/mxs-saif.c
index 07f8cf9980e31afe73d3b695e7dd2f8f3f1a3de2..f2eda81985e27fd151a5ce7430c9f2a2ea516396 100644
(file)
--- a/
sound/soc/mxs/mxs-saif.c
+++ b/
sound/soc/mxs/mxs-saif.c
@@
-455,7
+455,10
@@
static int mxs_saif_hw_params(struct snd_pcm_substream *substream,
* basic clock which should be fast enough for the internal
* logic.
*/
- clk_enable(saif->clk);
+ ret = clk_enable(saif->clk);
+ if (ret)
+ return ret;
+
ret = clk_set_rate(saif->clk, 24000000);
clk_disable(saif->clk);
if (ret)