patch-2.1.63 linux/drivers/sound/midibuf.c

Next file: linux/drivers/sound/mpu401.c
Previous file: linux/drivers/sound/midi_synth.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.62/linux/drivers/sound/midibuf.c linux/drivers/sound/midibuf.c
@@ -16,7 +16,7 @@
 
 #include "sound_config.h"
 
-#if defined(CONFIG_MIDI)
+#ifdef CONFIG_MIDI
 
 /*
  * Don't make MAX_QUEUE_SIZE larger than 4000
@@ -93,7 +93,7 @@
    */
 
   if (midi_devs[dev]->buffer_status != NULL)
-    while (!signal_pending(current) &&
+    while (!(current->signal & ~current->blocked) &&
 	   midi_devs[dev]->buffer_status (dev))
 
       {
@@ -289,7 +289,7 @@
 						   * devices
 						 */
 
-      while (!signal_pending(current) &&
+      while (!(current->signal & ~current->blocked) &&
 	     DATA_AVAIL (midi_out_buf[dev]))
 
 	{
@@ -370,8 +370,8 @@
 		  midi_sleep_flag[dev].opts |= WK_TIMEOUT;
 	      }
 	    midi_sleep_flag[dev].opts &= ~WK_SLEEP;
-	  }
-	  if (signal_pending(current))
+	  };
+	  if ((current->signal & ~current->blocked))
 	    {
 	      restore_flags (flags);
 	      return -EINTR;
@@ -430,7 +430,7 @@
 	  }
 	input_sleep_flag[dev].opts &= ~WK_SLEEP;
       };
-      if (signal_pending(current))
+      if ((current->signal & ~current->blocked))
 	c = -EINTR;		/*
 				   * The user is getting restless
 				 */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov