aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/davinci
diff options
context:
space:
mode:
authorPeter Ujfalusi <peter.ujfalusi@ti.com>2014-01-30 08:15:24 -0500
committerMark Brown <broonie@linaro.org>2014-01-31 11:38:24 -0500
commit0f7d9a635b7d1b120884b13d8763c9499e8a4aca (patch)
treeda11e27c85b231ad989c16aefec872d99f568377 /sound/soc/davinci
parent61d384aed4e8fbfafe3909a706935a03223c1254 (diff)
ASoC: davinci-mcasp: Return value handling cleanup for mcasp_common_hw_param()
Take the return value from mcasp_common_hw_param() and use that in case of error. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc/davinci')
-rw-r--r--sound/soc/davinci/davinci-mcasp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/davinci-mcasp.c
index f662ef22b8ae..f837b0a4f6f4 100644
--- a/sound/soc/davinci/davinci-mcasp.c
+++ b/sound/soc/davinci/davinci-mcasp.c
@@ -631,8 +631,10 @@ static int davinci_mcasp_hw_params(struct snd_pcm_substream *substream,
631 631
632 active_serializers = (channels + slots - 1) / slots; 632 active_serializers = (channels + slots - 1) / slots;
633 633
634 if (mcasp_common_hw_param(mcasp, substream->stream, channels) == -EINVAL) 634 ret = mcasp_common_hw_param(mcasp, substream->stream, channels);
635 return -EINVAL; 635 if (ret)
636 return ret;
637
636 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) 638 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
637 fifo_level = mcasp->txnumevt * active_serializers; 639 fifo_level = mcasp->txnumevt * active_serializers;
638 else 640 else