diff options
author | Deepak Nibade <dnibade@nvidia.com> | 2014-04-11 16:27:57 +0530 |
---|---|---|
committer | Deepak Nibade <dnibade@nvidia.com> | 2014-04-14 02:32:40 -0700 |
commit | 9ebcadf85e8da6630f35b62c904edacc7ab5843e (patch) | |
tree | 5ad16b0417dd2add6067554a485562c641041921 /sound | |
parent | 77243b00b48e921d1281b1eeaf74db934d32ce8a (diff) |
ASoC: Tegra: fix unchecked return value
Fix Coverity issue of unchecked error return
value of a function
Coverity id : 26068
Bug 1416640
Change-Id: I21b560985b1e36a98f5ce0c8b8a2566dc7a02e25
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/395192
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sumit Bhattacharya <sumitb@nvidia.com>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/tegra/tegra30_avp.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/soc/tegra/tegra30_avp.c b/sound/soc/tegra/tegra30_avp.c index 6416a866ba04..c8c5771780ff 100644 --- a/sound/soc/tegra/tegra30_avp.c +++ b/sound/soc/tegra/tegra30_avp.c @@ -1004,8 +1004,12 @@ static int tegra30_avp_compr_set_params(int id, stream->source_buffer_size = (params->fragments * params->fragment_size); - tegra30_avp_mem_alloc(&avp_stream->source_buf, + ret = tegra30_avp_mem_alloc(&avp_stream->source_buf, stream->source_buffer_size); + if (ret < 0) { + dev_err(audio_avp->dev, "Failed to allocate source buf memory"); + return ret; + } stream->source_buffer_system = avp_stream->source_buf.virt_addr; stream->source_buffer_avp = avp_stream->source_buf.phys_addr; |