diff options
author | Alan Cox <alan@linux.intel.com> | 2009-07-20 17:05:27 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-07-21 01:38:43 +0200 |
commit | 23198fda7182969b619613a555f8645fdc3dc334 (patch) | |
tree | d6c322a36d955958ab89ffb0a1a7327dc84e180c /drivers/char/pcmcia | |
parent | specialix.c: convert nested spin_lock_irqsave to spin_lock (diff) | |
download | linux-23198fda7182969b619613a555f8645fdc3dc334.tar.xz linux-23198fda7182969b619613a555f8645fdc3dc334.zip |
tty: fix chars_in_buffers
This function does not have an error return and returning an error is
instead interpreted as having a lot of pending bytes.
Reported by Jeff Harris who provided a list of some of the remaining
offenders.
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/pcmcia')
-rw-r--r-- | drivers/char/pcmcia/ipwireless/tty.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/pcmcia/ipwireless/tty.c b/drivers/char/pcmcia/ipwireless/tty.c index 569f2f7743a7..674b3ab3587d 100644 --- a/drivers/char/pcmcia/ipwireless/tty.c +++ b/drivers/char/pcmcia/ipwireless/tty.c @@ -320,10 +320,10 @@ static int ipw_chars_in_buffer(struct tty_struct *linux_tty) struct ipw_tty *tty = linux_tty->driver_data; if (!tty) - return -ENODEV; + return 0; if (!tty->open_count) - return -EINVAL; + return 0; return tty->tx_bytes_queued; } |