summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2021-10-25 21:59:32 +0300
committerMark Brown <broonie@kernel.org>2021-10-27 13:31:15 +0300
commit439c06f341aa1f09ad7def774998db1076946c98 (patch)
treea19e7c7650bfd833b329887297cc0c3f146218e5 /sound
parent73983ad922764e747d40b486ec7c2526e0355db1 (diff)
downloadlinux-439c06f341aa1f09ad7def774998db1076946c98.tar.xz
ASoC: mediatek: mt8195: fix return value
cppcheck reports the following warning: sound/soc/mediatek/mt8195/mt8195-dai-etdm.c:1299:10: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] int ret = 0; ^ The suggested change aligns the implementation of mt8195_afe_disable_etdm() with mt8195_afe_enable_etdm() - same negative return value upon error. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20211025185933.144327-8-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/mediatek/mt8195/mt8195-dai-etdm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/mediatek/mt8195/mt8195-dai-etdm.c b/sound/soc/mediatek/mt8195/mt8195-dai-etdm.c
index ac591d453e1e..c02c10da3600 100644
--- a/sound/soc/mediatek/mt8195/mt8195-dai-etdm.c
+++ b/sound/soc/mediatek/mt8195/mt8195-dai-etdm.c
@@ -1316,7 +1316,7 @@ static int mt8195_afe_disable_etdm(struct mtk_base_afe *afe, int dai_id)
}
out:
spin_unlock_irqrestore(&afe_priv->afe_ctrl_lock, flags);
- return 0;
+ return ret;
}
static int etdm_cowork_slv_sel(int id, int slave_mode)