diff options
author | Jon Hunter <jonathanh@nvidia.com> | 2018-05-30 11:15:19 -0400 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-05-30 11:34:28 -0400 |
commit | b91530f0a39edd82aa1b286bd921d052eb747f31 (patch) | |
tree | c8b4524240c07c3d3ed68c5630cf210feb0a5f97 | |
parent | c25f2566250cc58491a489c854013aecdf75dfef (diff) |
ASoC: core: Fix return code shown on error for hw_params
When the call to hw_params for a component fails, the error code is held
by the variable '__ret' but the error message displays the value held by
the variable 'ret'. Fix the return code shown when hw_params fails for
a component.
Fixes: b8135864d4d3 ("ASoC: snd_soc_component_driver has snd_pcm_ops")
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r-- | sound/soc/soc-pcm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index 0e2b2c6c60bd..5e7ae47a9658 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c | |||
@@ -956,7 +956,7 @@ static int soc_pcm_hw_params(struct snd_pcm_substream *substream, | |||
956 | if (__ret < 0) { | 956 | if (__ret < 0) { |
957 | dev_err(component->dev, | 957 | dev_err(component->dev, |
958 | "ASoC: %s hw params failed: %d\n", | 958 | "ASoC: %s hw params failed: %d\n", |
959 | component->name, ret); | 959 | component->name, __ret); |
960 | ret = __ret; | 960 | ret = __ret; |
961 | } | 961 | } |
962 | } | 962 | } |