diff options
author | Alan Cox <alan@linux.intel.com> | 2012-09-17 07:03:39 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-09-17 07:45:29 -0400 |
commit | d83114e9754cf5deb3424217ff2f10cace1428e3 (patch) | |
tree | 55bcfb35785ec1c3f4ffed4797938c36ac567402 /drivers/tty/hvc | |
parent | 7ac3c93e5dd74486ca4f8f0b02ae55182658d2e5 (diff) |
tty: Fix hvc return
HVC returns a size of -1 bytes for the write room in some cases.
This is bogus and not handled by the tty layer at all.
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/hvc')
-rw-r--r-- | drivers/tty/hvc/hvc_console.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/hvc/hvc_console.c b/drivers/tty/hvc/hvc_console.c index 7f80f15681cd..4a652999380f 100644 --- a/drivers/tty/hvc/hvc_console.c +++ b/drivers/tty/hvc/hvc_console.c | |||
@@ -558,7 +558,7 @@ static int hvc_write_room(struct tty_struct *tty) | |||
558 | struct hvc_struct *hp = tty->driver_data; | 558 | struct hvc_struct *hp = tty->driver_data; |
559 | 559 | ||
560 | if (!hp) | 560 | if (!hp) |
561 | return -1; | 561 | return 0; |
562 | 562 | ||
563 | return hp->outbuf_size - hp->n_outbuf; | 563 | return hp->outbuf_size - hp->n_outbuf; |
564 | } | 564 | } |