summaryrefslogtreecommitdiff
path: root/drivers/tty/serial
diff options
context:
space:
mode:
authorBaolin Wang <baolin.wang@linaro.org>2018-09-17 11:33:43 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-09-18 16:07:24 +0200
commitdd22161eef8b19930aa4439722940f44e2aff521 (patch)
treee3c692950131423731d94e9910ba1d209965bbcd /drivers/tty/serial
parent262d3dc00730f7a9d835faeca46689d750177e55 (diff)
serial: sprd: Change 'int' to 'unsigned int'
The register offset value should be 'unsigned int' type. Moreover, prefer 'unsigned int' to bare use of 'unsigned'. Signed-off-by: Baolin Wang <baolin.wang@linaro.org> Acked-by: Chunyan Zhang <chunyan.zhang@spreadtrum.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial')
-rw-r--r--drivers/tty/serial/sprd_serial.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/tty/serial/sprd_serial.c b/drivers/tty/serial/sprd_serial.c
index 03b0cd45f1ed..8d5c9cd6024c 100644
--- a/drivers/tty/serial/sprd_serial.c
+++ b/drivers/tty/serial/sprd_serial.c
@@ -109,12 +109,14 @@ struct sprd_uart_port {
static struct sprd_uart_port *sprd_port[UART_NR_MAX];
static int sprd_ports_num;
-static inline unsigned int serial_in(struct uart_port *port, int offset)
+static inline unsigned int serial_in(struct uart_port *port,
+ unsigned int offset)
{
return readl_relaxed(port->membase + offset);
}
-static inline void serial_out(struct uart_port *port, int offset, int value)
+static inline void serial_out(struct uart_port *port, unsigned int offset,
+ int value)
{
writel_relaxed(value, port->membase + offset);
}
@@ -598,8 +600,7 @@ static void sprd_putc(struct uart_port *port, int c)
writeb(c, port->membase + SPRD_TXD);
}
-static void sprd_early_write(struct console *con, const char *s,
- unsigned n)
+static void sprd_early_write(struct console *con, const char *s, unsigned int n)
{
struct earlycon_device *dev = con->data;