diff options
author | Peter Hurley <peter@hurleysoftware.com> | 2016-04-09 17:06:48 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-04-30 09:26:55 -0700 |
commit | 18900ca65a8553edc608b6c9d518eb31e6c09ba1 (patch) | |
tree | 6712f933f9145ce4ad365388817266c0c9ebac68 /drivers/tty/amiserial.c | |
parent | 1aabf523a288b09d660992c22e307110c70f746d (diff) | |
download | linux-rpi-18900ca65a8553edc608b6c9d518eb31e6c09ba1.tar.gz linux-rpi-18900ca65a8553edc608b6c9d518eb31e6c09ba1.tar.bz2 linux-rpi-18900ca65a8553edc608b6c9d518eb31e6c09ba1.zip |
tty: Replace TTY_IO_ERROR bit tests with tty_io_error()
Abstract TTY_IO_ERROR status test treewide with tty_io_error().
NB: tty->flags uses atomic bit ops; replace non-atomic bit test
with test_bit().
Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/amiserial.c')
-rw-r--r-- | drivers/tty/amiserial.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/tty/amiserial.c b/drivers/tty/amiserial.c index eacf4c9f3b29..183e98e84d09 100644 --- a/drivers/tty/amiserial.c +++ b/drivers/tty/amiserial.c @@ -1143,7 +1143,7 @@ static int rs_tiocmget(struct tty_struct *tty) if (serial_paranoia_check(info, tty->name, "rs_ioctl")) return -ENODEV; - if (tty->flags & (1 << TTY_IO_ERROR)) + if (tty_io_error(tty)) return -EIO; control = info->MCR; @@ -1165,7 +1165,7 @@ static int rs_tiocmset(struct tty_struct *tty, unsigned int set, if (serial_paranoia_check(info, tty->name, "rs_ioctl")) return -ENODEV; - if (tty->flags & (1 << TTY_IO_ERROR)) + if (tty_io_error(tty)) return -EIO; local_irq_save(flags); @@ -1250,7 +1250,7 @@ static int rs_ioctl(struct tty_struct *tty, if ((cmd != TIOCGSERIAL) && (cmd != TIOCSSERIAL) && (cmd != TIOCSERCONFIG) && (cmd != TIOCSERGSTRUCT) && (cmd != TIOCMIWAIT) && (cmd != TIOCGICOUNT)) { - if (tty->flags & (1 << TTY_IO_ERROR)) + if (tty_io_error(tty)) return -EIO; } |