From: Dimitris Papastamos Date: Fri, 1 Nov 2013 15:56:53 +0000 (+0000) Subject: ASoC: wm_adsp: Release firmware on memory allocation failure X-Git-Tag: firefly_0821_release~176^2~4889^2~33^2~47^2~3 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=7328823d0052bbdb15af162f9f510ced811bdfe8;p=firefly-linux-kernel-4.4.55.git ASoC: wm_adsp: Release firmware on memory allocation failure Signed-off-by: Dimitris Papastamos Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c index 076da025ba84..4008ceb77c5b 100644 --- a/sound/soc/codecs/wm_adsp.c +++ b/sound/soc/codecs/wm_adsp.c @@ -689,7 +689,8 @@ static int wm_adsp_load(struct wm_adsp *dsp) &buf_list); if (!buf) { adsp_err(dsp, "Out of memory\n"); - return -ENOMEM; + ret = -ENOMEM; + goto out_fw; } ret = regmap_raw_write_async(regmap, reg, buf->buf,