[I810_AUDIO] 9/x: Fix drain_dac loop when signals_allowed == 0

From: Herbert Xu
Date: Sat Nov 22 2003 - 19:02:55 EST


This patch fixes another bug in the drain_dac wait loop when it is
called with signals_allowed == 0.
--
Debian GNU/Linux 3.0 is out! ( http://www.debian.org/ )
Email: Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Index: kernel-source-2.4/drivers/sound/i810_audio.c
===================================================================
RCS file: /home/gondolin/herbert/src/CVS/debian/kernel-source-2.4/drivers/sound/i810_audio.c,v
retrieving revision 1.16
diff -u -r1.16 i810_audio.c
--- kernel-source-2.4/drivers/sound/i810_audio.c 22 Nov 2003 23:53:34 -0000 1.16
+++ kernel-source-2.4/drivers/sound/i810_audio.c 22 Nov 2003 23:55:57 -0000
@@ -1281,7 +1281,8 @@
* instead of actually sleeping and waiting for an
* interrupt to wake us up!
*/
- __set_current_state(TASK_INTERRUPTIBLE);
+ __set_current_state(signals_allowed ?
+ TASK_INTERRUPTIBLE : TASK_UNINTERRUPTIBLE);
spin_unlock_irqrestore(&state->card->lock, flags);

if (count <= 0)