diff options
Diffstat (limited to 'sound/oss/ali5455.c')
-rw-r--r-- | sound/oss/ali5455.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sound/oss/ali5455.c b/sound/oss/ali5455.c index 9c9e6c0410f2..62bb936b1f3d 100644 --- a/sound/oss/ali5455.c +++ b/sound/oss/ali5455.c | |||
@@ -64,6 +64,8 @@ | |||
64 | #include <linux/smp_lock.h> | 64 | #include <linux/smp_lock.h> |
65 | #include <linux/ac97_codec.h> | 65 | #include <linux/ac97_codec.h> |
66 | #include <linux/interrupt.h> | 66 | #include <linux/interrupt.h> |
67 | #include <linux/mutex.h> | ||
68 | |||
67 | #include <asm/uaccess.h> | 69 | #include <asm/uaccess.h> |
68 | 70 | ||
69 | #ifndef PCI_DEVICE_ID_ALI_5455 | 71 | #ifndef PCI_DEVICE_ID_ALI_5455 |
@@ -234,7 +236,7 @@ struct ali_state { | |||
234 | struct ali_card *card; /* Card info */ | 236 | struct ali_card *card; /* Card info */ |
235 | 237 | ||
236 | /* single open lock mechanism, only used for recording */ | 238 | /* single open lock mechanism, only used for recording */ |
237 | struct semaphore open_sem; | 239 | struct mutex open_mutex; |
238 | wait_queue_head_t open_wait; | 240 | wait_queue_head_t open_wait; |
239 | 241 | ||
240 | /* file mode */ | 242 | /* file mode */ |
@@ -2807,7 +2809,7 @@ found_virt: | |||
2807 | state->card = card; | 2809 | state->card = card; |
2808 | state->magic = ALI5455_STATE_MAGIC; | 2810 | state->magic = ALI5455_STATE_MAGIC; |
2809 | init_waitqueue_head(&dmabuf->wait); | 2811 | init_waitqueue_head(&dmabuf->wait); |
2810 | init_MUTEX(&state->open_sem); | 2812 | mutex_init(&state->open_mutex); |
2811 | file->private_data = state; | 2813 | file->private_data = state; |
2812 | dmabuf->trigger = 0; | 2814 | dmabuf->trigger = 0; |
2813 | /* allocate hardware channels */ | 2815 | /* allocate hardware channels */ |
@@ -3359,7 +3361,7 @@ static void __devinit ali_configure_clocking(void) | |||
3359 | state->card = card; | 3361 | state->card = card; |
3360 | state->magic = ALI5455_STATE_MAGIC; | 3362 | state->magic = ALI5455_STATE_MAGIC; |
3361 | init_waitqueue_head(&dmabuf->wait); | 3363 | init_waitqueue_head(&dmabuf->wait); |
3362 | init_MUTEX(&state->open_sem); | 3364 | mutex_init(&state->open_mutex); |
3363 | dmabuf->fmt = ALI5455_FMT_STEREO | ALI5455_FMT_16BIT; | 3365 | dmabuf->fmt = ALI5455_FMT_STEREO | ALI5455_FMT_16BIT; |
3364 | dmabuf->trigger = PCM_ENABLE_OUTPUT; | 3366 | dmabuf->trigger = PCM_ENABLE_OUTPUT; |
3365 | ali_set_dac_rate(state, 48000); | 3367 | ali_set_dac_rate(state, 48000); |