summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2009-03-11 20:11:40 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2009-03-23 14:59:58 -0700
commit94dc1155bafe2eebb97e5d591904fad6add37f83 (patch)
tree3d200d81c47352f63f4a30fb484d9d4ab3461265 /sound
parent3e5c20fcaa584230da862c094bec61a6c44b34a6 (diff)
ALSA: pcm_oss, fix locking typo
commit 91054598f794fb5d8a0b1e747ff8e2e8fc2115b3 upstream. s/mutex_lock/mutex_unlock/ on 2 fail paths in snd_pcm_oss_proc_write. Probably a typo, lock should be unlocked when leaving the function. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/core/oss/pcm_oss.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/core/oss/pcm_oss.c b/sound/core/oss/pcm_oss.c
index 4c601b192ddf..35afb418e4df 100644
--- a/sound/core/oss/pcm_oss.c
+++ b/sound/core/oss/pcm_oss.c
@@ -2854,7 +2854,7 @@ static void snd_pcm_oss_proc_write(struct snd_info_entry *entry,
setup = kmalloc(sizeof(*setup), GFP_KERNEL);
if (! setup) {
buffer->error = -ENOMEM;
- mutex_lock(&pstr->oss.setup_mutex);
+ mutex_unlock(&pstr->oss.setup_mutex);
return;
}
if (pstr->oss.setup_list == NULL)
@@ -2868,7 +2868,7 @@ static void snd_pcm_oss_proc_write(struct snd_info_entry *entry,
if (! template.task_name) {
kfree(setup);
buffer->error = -ENOMEM;
- mutex_lock(&pstr->oss.setup_mutex);
+ mutex_unlock(&pstr->oss.setup_mutex);
return;
}
}