diff options
author | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2016-03-31 20:23:15 +0200 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-03-31 20:43:08 +0200 |
commit | cef794f76485f4a4e6affd851ae9f9d0eb4287a5 (patch) | |
tree | ea0f4cb00795c7dfde003838bc977b3310cbccfb | |
parent | ASoC: qcom: Fix uninitialized symbol warning. (diff) | |
download | linux-cef794f76485f4a4e6affd851ae9f9d0eb4287a5.tar.xz linux-cef794f76485f4a4e6affd851ae9f9d0eb4287a5.zip |
ASoC: qcom: remove IS_ERR_VALUE usage on int.
IS_ERR_VALUE should be used only with unsigned long type,
signed types should use comparison 'ret < 0'
This patch removes such usages.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r-- | sound/soc/qcom/lpass-platform.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/soc/qcom/lpass-platform.c b/sound/soc/qcom/lpass-platform.c index f5cae01d18bd..db000c6987a1 100644 --- a/sound/soc/qcom/lpass-platform.c +++ b/sound/soc/qcom/lpass-platform.c @@ -491,7 +491,7 @@ static int lpass_platform_pcm_new(struct snd_soc_pcm_runtime *soc_runtime) data->rdma_ch = v->alloc_dma_channel(drvdata, SNDRV_PCM_STREAM_PLAYBACK); - if (IS_ERR_VALUE(data->rdma_ch)) + if (data->rdma_ch < 0) return data->rdma_ch; drvdata->substream[data->rdma_ch] = psubstream; @@ -518,8 +518,10 @@ static int lpass_platform_pcm_new(struct snd_soc_pcm_runtime *soc_runtime) data->wrdma_ch = v->alloc_dma_channel(drvdata, SNDRV_PCM_STREAM_CAPTURE); - if (IS_ERR_VALUE(data->wrdma_ch)) + if (data->wrdma_ch < 0) { + ret = data->wrdma_ch; goto capture_alloc_err; + } drvdata->substream[data->wrdma_ch] = csubstream; |