summaryrefslogtreecommitdiff
path: root/drivers/tty/serial/8250
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2021-05-05 12:19:17 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-05-13 19:29:11 +0300
commit9a33fbf9d23034d7e89849c587b0aed0e4cf794d (patch)
tree01de10803e6c4224214136acba1c91a2004022c6 /drivers/tty/serial/8250
parent03b3b1a2405ccd71570cd5ec1fe4abd7bb4891cb (diff)
downloadlinux-9a33fbf9d23034d7e89849c587b0aed0e4cf794d.tar.xz
tty: make tty_buffer_space_avail return uint
tty_buffer_space_avail returns values >= 0, so make it clear by the return type. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: Joel Stanley <joel@jms.id.au> Link: https://lore.kernel.org/r/20210505091928.22010-25-jslaby@suse.cz Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/8250')
-rw-r--r--drivers/tty/serial/8250/8250_aspeed_vuart.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/tty/serial/8250/8250_aspeed_vuart.c b/drivers/tty/serial/8250/8250_aspeed_vuart.c
index 2bf1d8582d9a..a28a394ba32a 100644
--- a/drivers/tty/serial/8250/8250_aspeed_vuart.c
+++ b/drivers/tty/serial/8250/8250_aspeed_vuart.c
@@ -329,7 +329,7 @@ static int aspeed_vuart_handle_irq(struct uart_port *port)
{
struct uart_8250_port *up = up_to_u8250p(port);
unsigned int iir, lsr;
- int space, count;
+ unsigned int space, count;
iir = serial_port_in(port, UART_IIR);
@@ -353,7 +353,7 @@ static int aspeed_vuart_handle_irq(struct uart_port *port)
jiffies + unthrottle_timeout);
} else {
- count = min(space, 256);
+ count = min(space, 256U);
do {
serial8250_read_char(up, lsr);