]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - drivers/tty/serial/crisv10.c
tty: Replace TTY_IO_ERROR bit tests with tty_io_error()
[mirror_ubuntu-artful-kernel.git] / drivers / tty / serial / crisv10.c
index c0172bf54a9b3d8052fc6416f6731d1a45a6c9eb..5469903348153c91301b5cf62035d0451e055406 100644 (file)
@@ -3445,7 +3445,7 @@ rs_ioctl(struct tty_struct *tty,
        if ((cmd != TIOCGSERIAL) && (cmd != TIOCSSERIAL) &&
            (cmd != TIOCSERCONFIG) && (cmd != TIOCSERGWILD)  &&
            (cmd != TIOCSERSWILD) && (cmd != TIOCSERGSTRUCT)) {
-               if (tty->flags & (1 << TTY_IO_ERROR))
+               if (tty_io_error(tty))
                        return -EIO;
        }
 
@@ -3755,8 +3755,7 @@ block_til_ready(struct tty_struct *tty, struct file * filp,
         * If non-blocking mode is set, or the port is not enabled,
         * then make the check up front and then exit.
         */
-       if ((filp->f_flags & O_NONBLOCK) ||
-           (tty->flags & (1 << TTY_IO_ERROR))) {
+       if ((filp->f_flags & O_NONBLOCK) || tty_io_error(tty)) {
                info->port.flags |= ASYNC_NORMAL_ACTIVE;
                return 0;
        }