ALSA: pcm_core: Fix wake_up() optimization

This change fixes the "ALSA: pcm_lib - optimize wake_up() calls for PCM I/O"
commit. New sleeping queue is introduced to separate user space and kernel
space wake_ups. runtime->nowake is renamed to twake (transfer wake).

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
Jaroslav Kysela
2010-01-21 10:32:15 +01:00
parent d1db38c015
commit c91a988dc6
4 changed files with 17 additions and 12 deletions

View File

@ -311,8 +311,9 @@ struct snd_pcm_runtime {
struct snd_pcm_mmap_control *control;
/* -- locking / scheduling -- */
unsigned int nowake: 1; /* no wakeup (data-copy in progress) */
wait_queue_head_t sleep;
unsigned int twake: 1; /* do transfer (!poll) wakeup */
wait_queue_head_t sleep; /* poll sleep */
wait_queue_head_t tsleep; /* transfer sleep */
struct fasync_struct *fasync;
/* -- private section -- */