summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/jz4760.c
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2021-03-02 14:59:19 -0600
committerMark Brown <broonie@kernel.org>2021-03-10 13:10:38 +0000
commitc5036b86678fcc17bc49f85b03bd1a0ac8524646 (patch)
treeba76e3aa2de3fd5027eb308475aea9d01cc2c13a /sound/soc/codecs/jz4760.c
parent80cd73094c4096b3ce4d57cb8cf2c3e341c6de97 (diff)
ASoC: jz4760: fix set but not used warning
make W=1 warning: sound/soc/codecs/jz4760.c: In function ‘jz4760_codec_startup’: sound/soc/codecs/jz4760.c:201:6: error: variable ‘ret’ set but not used [-Werror=unused-but-set-variable] 201 | int ret; | ^~~ Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20210302205926.49063-3-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/jz4760.c')
-rw-r--r--sound/soc/codecs/jz4760.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/codecs/jz4760.c b/sound/soc/codecs/jz4760.c
index e8f28ccc145a..f62abf5ad917 100644
--- a/sound/soc/codecs/jz4760.c
+++ b/sound/soc/codecs/jz4760.c
@@ -198,7 +198,7 @@ static int jz4760_codec_startup(struct snd_pcm_substream *substream,
{
struct snd_soc_component *codec = dai->component;
struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(codec);
- int ret;
+ int ret = 0;
/*
* SYSCLK output from the codec to the AIC is required to keep the
@@ -207,7 +207,7 @@ static int jz4760_codec_startup(struct snd_pcm_substream *substream,
*/
if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
ret = snd_soc_dapm_force_enable_pin(dapm, "SYSCLK");
- return 0;
+ return ret;
}
static void jz4760_codec_shutdown(struct snd_pcm_substream *substream,