[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201204021350.28182-1-wanghai38@huawei.com>
Date: Fri, 4 Dec 2020 10:13:50 +0800
From: Wang Hai <wanghai38@...wei.com>
To: <johan@...nel.org>, <elder@...nel.org>,
<gregkh@...uxfoundation.org>, <dan.carpenter@...cle.com>,
<aibhav.sr@...il.com>
CC: <greybus-dev@...ts.linaro.org>, <devel@...verdev.osuosl.org>,
<linux-kernel@...r.kernel.org>
Subject: [PATCH] staging: greybus: audio: Add missing unlock in gbaudio_dapm_free_controls()
Add the missing unlock before return from function
gbaudio_dapm_free_controls() in the error handling case.
Fixes: 510e340efe0c ("staging: greybus: audio: Add helper APIs for dynamic audio module")
Reported-by: Hulk Robot <hulkci@...wei.com>
Signed-off-by: Wang Hai <wanghai38@...wei.com>
---
drivers/staging/greybus/audio_helper.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/staging/greybus/audio_helper.c b/drivers/staging/greybus/audio_helper.c
index 237531ba60f3..293675dbea10 100644
--- a/drivers/staging/greybus/audio_helper.c
+++ b/drivers/staging/greybus/audio_helper.c
@@ -135,6 +135,7 @@ int gbaudio_dapm_free_controls(struct snd_soc_dapm_context *dapm,
if (!w) {
dev_err(dapm->dev, "%s: widget not found\n",
widget->name);
+ mutex_unlock(&dapm->card->dapm_mutex);
return -EINVAL;
}
widget++;
--
2.17.1
Powered by blists - more mailing lists