[ALSA] Fix PCM write blocking
authorTakashi Iwai <tiwai@suse.de>
Tue, 8 Jan 2008 17:00:04 +0000 (18:00 +0100)
committerJaroslav Kysela <perex@perex.cz>
Thu, 31 Jan 2008 16:29:46 +0000 (17:29 +0100)
commitfa5717f2099aadb2083d5df4d19af8f9685fa03e
tree563694ca22b8dd11467208457ccde81240c080f9
parent8ace4f3c9d83fd60e7539526a3a70bf5730db8c0
[ALSA] Fix PCM write blocking

The snd_pcm_lib_write1() may block in some weird condition:
  - the stream isn't started
  - avail_min is big (e.g. period size)
  - partial write up to buffer_size - avail_min
The patch fixes this invalid blocking problem.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
sound/core/pcm_lib.c