diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2021-01-11 12:50:21 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-01-11 17:03:55 +0300 |
commit | e91b65b36fde0690f1c694f17dd1b549295464a7 (patch) | |
tree | 3679a02263c8cd8215317b1bf113b1faf4362de7 /sound/soc/soc-pcm.c | |
parent | fe9989fb25b0cea6414e72e0514c70ed8b158c28 (diff) | |
download | linux-e91b65b36fde0690f1c694f17dd1b549295464a7.tar.xz |
ASoC: soc-pcm: Fix an uninitialized error code
The error path here doesn't set "ret" so it returns uninitialized data
instead of a negative error code.
Fixes: 2c1382840c19 ("ASoC: soc-pcm: disconnect BEs if the FE is not ready")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/X/wfXQFxeMLvpO+1@mwanda
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-pcm.c')
-rw-r--r-- | sound/soc/soc-pcm.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index 29328ce39904..a253c9f918e1 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -2444,6 +2444,7 @@ static int dpcm_run_update_startup(struct snd_soc_pcm_runtime *fe, int stream) ret = -EINVAL; dev_err(fe->dev, "ASoC: FE %s is not ready %d\n", fe->dai_link->name, fe->dpcm[stream].state); + ret = -EINVAL; goto disconnect; } |