[ALSA] semaphore -> mutex (core 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>
This commit is contained in:

committed by
Jaroslav Kysela

parent
f0283f45a0
commit
1a60d4c5a0
@@ -23,7 +23,7 @@
|
||||
*/
|
||||
|
||||
#include <linux/sched.h> /* wake_up() */
|
||||
#include <asm/semaphore.h> /* struct semaphore */
|
||||
#include <linux/mutex.h> /* struct mutex */
|
||||
#include <linux/rwsem.h> /* struct rw_semaphore */
|
||||
#include <linux/workqueue.h> /* struct workqueue_struct */
|
||||
#include <linux/pm.h> /* pm_message_t */
|
||||
@@ -137,7 +137,7 @@ struct snd_card {
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
unsigned int power_state; /* power state */
|
||||
struct semaphore power_lock; /* power lock */
|
||||
struct mutex power_lock; /* power lock */
|
||||
wait_queue_head_t power_sleep;
|
||||
#endif
|
||||
|
||||
@@ -150,12 +150,12 @@ struct snd_card {
|
||||
#ifdef CONFIG_PM
|
||||
static inline void snd_power_lock(struct snd_card *card)
|
||||
{
|
||||
down(&card->power_lock);
|
||||
mutex_lock(&card->power_lock);
|
||||
}
|
||||
|
||||
static inline void snd_power_unlock(struct snd_card *card)
|
||||
{
|
||||
up(&card->power_lock);
|
||||
mutex_unlock(&card->power_lock);
|
||||
}
|
||||
|
||||
static inline unsigned int snd_power_get_state(struct snd_card *card)
|
||||
|
@@ -60,7 +60,7 @@ struct snd_hwdep {
|
||||
void *private_data;
|
||||
void (*private_free) (struct snd_hwdep *hwdep);
|
||||
|
||||
struct semaphore open_mutex;
|
||||
struct mutex open_mutex;
|
||||
int used;
|
||||
unsigned int dsp_loaded;
|
||||
unsigned int exclusive: 1;
|
||||
|
@@ -84,7 +84,7 @@ struct snd_info_entry {
|
||||
void *private_data;
|
||||
void (*private_free)(struct snd_info_entry *entry);
|
||||
struct proc_dir_entry *p;
|
||||
struct semaphore access;
|
||||
struct mutex access;
|
||||
};
|
||||
|
||||
#if defined(CONFIG_SND_OSSEMUL) && defined(CONFIG_PROC_FS)
|
||||
|
@@ -61,7 +61,7 @@ struct snd_mixer_oss {
|
||||
unsigned int active_index);
|
||||
void *private_data_recsrc;
|
||||
void (*private_free_recsrc)(struct snd_mixer_oss *mixer);
|
||||
struct semaphore reg_mutex;
|
||||
struct mutex reg_mutex;
|
||||
struct snd_info_entry *proc_entry;
|
||||
int oss_dev_alloc;
|
||||
/* --- */
|
||||
|
@@ -420,7 +420,7 @@ struct snd_pcm {
|
||||
char id[64];
|
||||
char name[80];
|
||||
struct snd_pcm_str streams[2];
|
||||
struct semaphore open_mutex;
|
||||
struct mutex open_mutex;
|
||||
wait_queue_head_t open_wait;
|
||||
void *private_data;
|
||||
void (*private_free) (struct snd_pcm *pcm);
|
||||
|
@@ -75,7 +75,7 @@ struct snd_pcm_oss_substream {
|
||||
|
||||
struct snd_pcm_oss_stream {
|
||||
struct snd_pcm_oss_setup *setup_list; /* setup list */
|
||||
struct semaphore setup_mutex;
|
||||
struct mutex setup_mutex;
|
||||
struct snd_info_entry *proc_entry;
|
||||
};
|
||||
|
||||
|
@@ -26,7 +26,7 @@
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/wait.h>
|
||||
#include <asm/semaphore.h>
|
||||
#include <linux/mutex.h>
|
||||
|
||||
#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
|
||||
#include "seq_device.h"
|
||||
@@ -130,7 +130,7 @@ struct snd_rawmidi {
|
||||
void *private_data;
|
||||
void (*private_free) (struct snd_rawmidi *rmidi);
|
||||
|
||||
struct semaphore open_mutex;
|
||||
struct mutex open_mutex;
|
||||
wait_queue_head_t open_wait;
|
||||
|
||||
struct snd_info_entry *dev;
|
||||
|
@@ -64,7 +64,7 @@ struct snd_seq_kinstr_list {
|
||||
|
||||
spinlock_t lock;
|
||||
spinlock_t ops_lock;
|
||||
struct semaphore ops_mutex;
|
||||
struct mutex ops_mutex;
|
||||
unsigned long ops_flags;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user