patch-2.1.57 linux/drivers/char/esp.c

Next file: linux/drivers/char/ftape/fdc-io.c
Previous file: linux/drivers/char/epca.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.56/linux/drivers/char/esp.c linux/drivers/char/esp.c
@@ -1733,7 +1733,7 @@
 
 	interruptible_sleep_on(&info->break_wait);
 
-	if (current->signal & ~current->blocked) {
+	if (signal_pending(current)) {
 		serial_out(info, UART_ESI_CMD1, ESI_ISSUE_BREAK);
 		serial_out(info, UART_ESI_CMD2, 0x00);
 		sti();
@@ -1775,11 +1775,11 @@
 			if (retval)
 				return retval;
 			tty_wait_until_sent(tty, 0);
-			if (current->signal & ~current->blocked)
+			if (signal_pending(current))
 				return -EINTR;
 			if (!arg) {
 				send_break(info, HZ/4);	/* 1/4 second */
-				if (current->signal & ~current->blocked)
+				if (signal_pending(current))
 					return -EINTR;
 			}
 			return 0;
@@ -1788,10 +1788,10 @@
 			if (retval)
 				return retval;
 			tty_wait_until_sent(tty, 0);
-			if (current->signal & ~current->blocked)
+			if (signal_pending(current))
 				return -EINTR;
 			send_break(info, arg ? arg*(HZ/10) : HZ/4);
-			if (current->signal & ~current->blocked)
+			if (signal_pending(current))
 				return -EINTR;
 			return 0;
 		case TIOCGSOFTCAR:
@@ -1845,7 +1845,7 @@
 			while (1) {
 				interruptible_sleep_on(&info->delta_msr_wait);
 				/* see if a signal did it */
-				if (current->signal & ~current->blocked)
+				if (signal_pending(current))
 					return -ERESTARTSYS;
 				cli();
 				cnow = info->icount;	/* atomic copy */
@@ -2086,7 +2086,7 @@
 		current->timeout = jiffies + char_time;
 		schedule();
 
-		if (current->signal & ~current->blocked)
+		if (signal_pending(current))
 			break;
 
 		if (timeout && ((orig_jiffies + timeout) < jiffies))
@@ -2243,7 +2243,7 @@
 		    !(info->flags & ASYNC_CLOSING) &&
 		    (do_clocal))
 			break;
-		if (current->signal & ~current->blocked) {
+		if (signal_pending(current)) {
 			retval = -ERESTARTSYS;
 			break;
 		}

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