mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] ASoC: Intel: fix missing mutex
@ 2014-11-02  6:34 Sudip Mukherjee
  2014-11-02 11:07 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Sudip Mukherjee @ 2014-11-02  6:34 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai
  Cc: Sudip Mukherjee, alsa-devel, linux-kernel

on error in block prepare, we were returning the error code while still
holding the mutex. We are releasing the mutex in this patch before
return.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
 sound/soc/intel/sst-firmware.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/intel/sst-firmware.c b/sound/soc/intel/sst-firmware.c
index 35788ad..dca6d9a 100644
--- a/sound/soc/intel/sst-firmware.c
+++ b/sound/soc/intel/sst-firmware.c
@@ -1120,6 +1120,7 @@ int sst_block_alloc_scratch(struct sst_dsp *dsp)
 	ret = block_list_prepare(dsp, &dsp->scratch_block_list);
 	if (ret < 0) {
 		dev_err(dsp->dev, "error: scratch block prepare failed\n");
+		mutex_unlock(&dsp->mutex);
 		return ret;
 	}
 
-- 
1.8.1.2


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] ASoC: Intel: fix missing mutex
  2014-11-02  6:34 [PATCH] ASoC: Intel: fix missing mutex Sudip Mukherjee
@ 2014-11-02 11:07 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2014-11-02 11:07 UTC (permalink / raw)
  To: Sudip Mukherjee
  Cc: Liam Girdwood, Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 236 bytes --]

On Sun, Nov 02, 2014 at 12:04:41PM +0530, Sudip Mukherjee wrote:
> on error in block prepare, we were returning the error code while still
> holding the mutex. We are releasing the mutex in this patch before
> return.

Applied, thanks.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-11-02 11:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-11-02  6:34 [PATCH] ASoC: Intel: fix missing mutex Sudip Mukherjee
2014-11-02 11:07 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®