diff options
| author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-03-23 23:44:19 -0500 |
|---|---|---|
| committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-03-23 23:44:19 -0500 |
| commit | 1ebbe2b20091d306453a5cf480a87e6cd28ae76f (patch) | |
| tree | f5cd7a0fa69b8b1938cb5a0faed2e7b0628072a5 /sound/core/oss/mixer_oss.c | |
| parent | ac58c9059da8886b5e8cde012a80266b18ca146e (diff) | |
| parent | 674a396c6d2ba0341ebdd7c1c9950f32f018e2dd (diff) | |
Merge branch 'linus'
Diffstat (limited to 'sound/core/oss/mixer_oss.c')
| -rw-r--r-- | sound/core/oss/mixer_oss.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sound/core/oss/mixer_oss.c b/sound/core/oss/mixer_oss.c index f08e65a2bffe..9c68bc3f97aa 100644 --- a/sound/core/oss/mixer_oss.c +++ b/sound/core/oss/mixer_oss.c | |||
| @@ -1095,7 +1095,7 @@ static void snd_mixer_oss_proc_read(struct snd_info_entry *entry, | |||
| 1095 | struct snd_mixer_oss *mixer = entry->private_data; | 1095 | struct snd_mixer_oss *mixer = entry->private_data; |
| 1096 | int i; | 1096 | int i; |
| 1097 | 1097 | ||
| 1098 | down(&mixer->reg_mutex); | 1098 | mutex_lock(&mixer->reg_mutex); |
| 1099 | for (i = 0; i < SNDRV_OSS_MAX_MIXERS; i++) { | 1099 | for (i = 0; i < SNDRV_OSS_MAX_MIXERS; i++) { |
| 1100 | struct slot *p; | 1100 | struct slot *p; |
| 1101 | 1101 | ||
| @@ -1110,7 +1110,7 @@ static void snd_mixer_oss_proc_read(struct snd_info_entry *entry, | |||
| 1110 | else | 1110 | else |
| 1111 | snd_iprintf(buffer, "\"\" 0\n"); | 1111 | snd_iprintf(buffer, "\"\" 0\n"); |
| 1112 | } | 1112 | } |
| 1113 | up(&mixer->reg_mutex); | 1113 | mutex_unlock(&mixer->reg_mutex); |
| 1114 | } | 1114 | } |
| 1115 | 1115 | ||
| 1116 | static void snd_mixer_oss_proc_write(struct snd_info_entry *entry, | 1116 | static void snd_mixer_oss_proc_write(struct snd_info_entry *entry, |
| @@ -1134,9 +1134,9 @@ static void snd_mixer_oss_proc_write(struct snd_info_entry *entry, | |||
| 1134 | cptr = snd_info_get_str(str, cptr, sizeof(str)); | 1134 | cptr = snd_info_get_str(str, cptr, sizeof(str)); |
| 1135 | if (! *str) { | 1135 | if (! *str) { |
| 1136 | /* remove the entry */ | 1136 | /* remove the entry */ |
| 1137 | down(&mixer->reg_mutex); | 1137 | mutex_lock(&mixer->reg_mutex); |
| 1138 | mixer_slot_clear(&mixer->slots[ch]); | 1138 | mixer_slot_clear(&mixer->slots[ch]); |
| 1139 | up(&mixer->reg_mutex); | 1139 | mutex_unlock(&mixer->reg_mutex); |
| 1140 | continue; | 1140 | continue; |
| 1141 | } | 1141 | } |
| 1142 | snd_info_get_str(idxstr, cptr, sizeof(idxstr)); | 1142 | snd_info_get_str(idxstr, cptr, sizeof(idxstr)); |
| @@ -1145,7 +1145,7 @@ static void snd_mixer_oss_proc_write(struct snd_info_entry *entry, | |||
| 1145 | snd_printk(KERN_ERR "mixer_oss: invalid index %d\n", idx); | 1145 | snd_printk(KERN_ERR "mixer_oss: invalid index %d\n", idx); |
| 1146 | continue; | 1146 | continue; |
| 1147 | } | 1147 | } |
| 1148 | down(&mixer->reg_mutex); | 1148 | mutex_lock(&mixer->reg_mutex); |
| 1149 | slot = (struct slot *)mixer->slots[ch].private_data; | 1149 | slot = (struct slot *)mixer->slots[ch].private_data; |
| 1150 | if (slot && slot->assigned && | 1150 | if (slot && slot->assigned && |
| 1151 | slot->assigned->index == idx && ! strcmp(slot->assigned->name, str)) | 1151 | slot->assigned->index == idx && ! strcmp(slot->assigned->name, str)) |
| @@ -1168,7 +1168,7 @@ static void snd_mixer_oss_proc_write(struct snd_info_entry *entry, | |||
| 1168 | kfree(tbl); | 1168 | kfree(tbl); |
| 1169 | } | 1169 | } |
| 1170 | __unlock: | 1170 | __unlock: |
| 1171 | up(&mixer->reg_mutex); | 1171 | mutex_unlock(&mixer->reg_mutex); |
| 1172 | } | 1172 | } |
| 1173 | } | 1173 | } |
| 1174 | 1174 | ||
| @@ -1288,7 +1288,7 @@ static int snd_mixer_oss_notify_handler(struct snd_card *card, int cmd) | |||
| 1288 | mixer = kcalloc(2, sizeof(*mixer), GFP_KERNEL); | 1288 | mixer = kcalloc(2, sizeof(*mixer), GFP_KERNEL); |
| 1289 | if (mixer == NULL) | 1289 | if (mixer == NULL) |
| 1290 | return -ENOMEM; | 1290 | return -ENOMEM; |
| 1291 | init_MUTEX(&mixer->reg_mutex); | 1291 | mutex_init(&mixer->reg_mutex); |
| 1292 | sprintf(name, "mixer%i%i", card->number, 0); | 1292 | sprintf(name, "mixer%i%i", card->number, 0); |
| 1293 | if ((err = snd_register_oss_device(SNDRV_OSS_DEVICE_TYPE_MIXER, | 1293 | if ((err = snd_register_oss_device(SNDRV_OSS_DEVICE_TYPE_MIXER, |
| 1294 | card, 0, | 1294 | card, 0, |
