]> Pileus Git - ~andy/linux/blobdiff - drivers/char/pcmcia/synclink_cs.c
Merge tag 'renesas-dt-fixes2-for-v3.14' of git://git.kernel.org/pub/scm/linux/kernel...
[~andy/linux] / drivers / char / pcmcia / synclink_cs.c
index d39cca659a3f4839233475d32a6d63c16553209d..8320abd1ef1473ddfda6820c8a6bcaa689f73824 100644 (file)
@@ -2511,8 +2511,8 @@ static int mgslpc_open(struct tty_struct *tty, struct file * filp)
 
        /* If port is closing, signal caller to try again */
        if (tty_hung_up_p(filp) || port->flags & ASYNC_CLOSING){
-               if (port->flags & ASYNC_CLOSING)
-                       interruptible_sleep_on(&port->close_wait);
+               wait_event_interruptible_tty(tty, port->close_wait,
+                                            !(port->flags & ASYNC_CLOSING));
                retval = ((port->flags & ASYNC_HUP_NOTIFY) ?
                        -EAGAIN : -ERESTARTSYS);
                goto cleanup;