projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
82fa8f5
)
ASoC: mediatek: remove unnecessary check of clk_disable_unprepare
author
Minghao Chi
<chi.minghao@zte.com.cn>
Thu, 2 Jun 2022 07:18:09 +0000
(07:18 +0000)
committer
Mark Brown
<broonie@kernel.org>
Mon, 6 Jun 2022 11:38:51 +0000
(12:38 +0100)
Because clk_disable_unprepare already checked NULL clock
parameter, so the additional checks are unnecessary, just remove them.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
Link:
https://lore.kernel.org/r/20220602071809.278134-1-chi.minghao@zte.com.cn
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/mediatek/mt8173/mt8173-afe-pcm.c
patch
|
blob
|
history
diff --git
a/sound/soc/mediatek/mt8173/mt8173-afe-pcm.c
b/sound/soc/mediatek/mt8173/mt8173-afe-pcm.c
index 31494930433f7fda5d2def43a64d170b2f9bc7a5..dcaeeeb8aac70f90aa0ba0d48e5e9801a65be0cc 100644
(file)
--- a/
sound/soc/mediatek/mt8173/mt8173-afe-pcm.c
+++ b/
sound/soc/mediatek/mt8173/mt8173-afe-pcm.c
@@
-286,10
+286,8
@@
static int mt8173_afe_dais_set_clks(struct mtk_base_afe *afe,
static void mt8173_afe_dais_disable_clks(struct mtk_base_afe *afe,
struct clk *m_ck, struct clk *b_ck)
{
- if (m_ck)
- clk_disable_unprepare(m_ck);
- if (b_ck)
- clk_disable_unprepare(b_ck);
+ clk_disable_unprepare(m_ck);
+ clk_disable_unprepare(b_ck);
}
static int mt8173_afe_i2s_startup(struct snd_pcm_substream *substream,