[ALSA] semaphore -> mutex (driver part)

Semaphore to mutex conversion.

The conversion was generated via scripts, and the result was validated
automatically via a script as well.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
这个提交包含在:
Ingo Molnar
2006-01-16 16:31:42 +01:00
提交者 Jaroslav Kysela
父节点 1a60d4c5a0
当前提交 ef9f0a42db
修改 22 个文件,包含 103 行新增99 行删除

查看文件

@@ -76,13 +76,13 @@ int snd_opl3_open(struct snd_hwdep * hw, struct file *file)
{
struct snd_opl3 *opl3 = hw->private_data;
down(&opl3->access_mutex);
mutex_lock(&opl3->access_mutex);
if (opl3->used) {
up(&opl3->access_mutex);
mutex_unlock(&opl3->access_mutex);
return -EAGAIN;
}
opl3->used++;
up(&opl3->access_mutex);
mutex_unlock(&opl3->access_mutex);
return 0;
}
@@ -179,9 +179,9 @@ int snd_opl3_release(struct snd_hwdep * hw, struct file *file)
struct snd_opl3 *opl3 = hw->private_data;
snd_opl3_reset(opl3);
down(&opl3->access_mutex);
mutex_lock(&opl3->access_mutex);
opl3->used--;
up(&opl3->access_mutex);
mutex_unlock(&opl3->access_mutex);
return 0;
}