All of lore.kernel.org
 help / color / mirror / Atom feed
From: Luo Meng <luomeng12@huawei.com>
To: <lgirdwood@gmail.com>, <broonie@kernel.org>, <perex@perex.cz>,
	<tiwai@suse.com>, <ckeepax@opensource.cirrus.com>,
	<kuninori.morimoto.gx@renesas.com>, <Vlad.Karpovich@cirrus.com>,
	<ranjani.sridharan@linux.intel.com>, <Adam.Brickman@cirrus.com>,
	<james.schulman@cirrus.com>, <piotrs@opensource.cirrus.com>,
	<rf@opensource.cirrus.com>, <wenshi@opensource.cirrus.com>,
	<patches@opensource.cirrus.com>, <alsa-devel@alsa-project.org>,
	<luomeng12@huawei.com>
Subject: [PATCH] ASoC: wm_adsp: fix error return code in wm_adsp_load()
Date: Mon, 23 Nov 2020 21:38:39 +0800	[thread overview]
Message-ID: <20201123133839.4073787-1-luomeng12@huawei.com> (raw)

Fix to return a negative error code from the error handling case
instead of 0 in function wm_adsp_load(), as done elsewhere in this
function.

Fixes: 170b1e123f38 ("ASoC: wm_adsp: Add support for new Halo core DSPs")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Luo Meng <luomeng12@huawei.com>
---
 sound/soc/codecs/wm_adsp.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c
index bcf18bf15a02..e61d00486c65 100644
--- a/sound/soc/codecs/wm_adsp.c
+++ b/sound/soc/codecs/wm_adsp.c
@@ -1937,6 +1937,7 @@ static int wm_adsp_load(struct wm_adsp *dsp)
 			mem = wm_adsp_find_region(dsp, type);
 			if (!mem) {
 				adsp_err(dsp, "No region of type: %x\n", type);
+				ret = -EINVAL;
 				goto out_fw;
 			}
 
-- 
2.25.4


             reply	other threads:[~2020-11-24 17:13 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-23 13:38 Luo Meng [this message]
2020-11-24  9:41 ` [PATCH] ASoC: wm_adsp: fix error return code in wm_adsp_load() Richard Fitzgerald
2020-11-25 13:58 ` Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201123133839.4073787-1-luomeng12@huawei.com \
    --to=luomeng12@huawei.com \
    --cc=Adam.Brickman@cirrus.com \
    --cc=Vlad.Karpovich@cirrus.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=ckeepax@opensource.cirrus.com \
    --cc=james.schulman@cirrus.com \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=lgirdwood@gmail.com \
    --cc=patches@opensource.cirrus.com \
    --cc=perex@perex.cz \
    --cc=piotrs@opensource.cirrus.com \
    --cc=ranjani.sridharan@linux.intel.com \
    --cc=rf@opensource.cirrus.com \
    --cc=tiwai@suse.com \
    --cc=wenshi@opensource.cirrus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.