summaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/8250/8250_uniphier.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2015-12-31 18:20:10 -0500
committerDavid S. Miller <davem@davemloft.net>2015-12-31 18:20:10 -0500
commitc07f30ad68053181b3e8a0e65b0630e12e844f91 (patch)
tree8758968aabc844c435ff2a5d7d02c835fccd02a3 /drivers/tty/serial/8250/8250_uniphier.c
parent7b22a7788b0263f42f7232c5c05c503424ffa0ba (diff)
parent9c982e86dbdbaa3fb248dfc776dddda32cbc8927 (diff)
downloadop-kernel-dev-c07f30ad68053181b3e8a0e65b0630e12e844f91.zip
op-kernel-dev-c07f30ad68053181b3e8a0e65b0630e12e844f91.tar.gz
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'drivers/tty/serial/8250/8250_uniphier.c')
-rw-r--r--drivers/tty/serial/8250/8250_uniphier.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/tty/serial/8250/8250_uniphier.c b/drivers/tty/serial/8250/8250_uniphier.c
index d11621e..245edbb 100644
--- a/drivers/tty/serial/8250/8250_uniphier.c
+++ b/drivers/tty/serial/8250/8250_uniphier.c
@@ -115,12 +115,16 @@ static void uniphier_serial_out(struct uart_port *p, int offset, int value)
*/
static int uniphier_serial_dl_read(struct uart_8250_port *up)
{
- return readl(up->port.membase + UNIPHIER_UART_DLR);
+ int offset = UNIPHIER_UART_DLR << up->port.regshift;
+
+ return readl(up->port.membase + offset);
}
static void uniphier_serial_dl_write(struct uart_8250_port *up, int value)
{
- writel(value, up->port.membase + UNIPHIER_UART_DLR);
+ int offset = UNIPHIER_UART_DLR << up->port.regshift;
+
+ writel(value, up->port.membase + offset);
}
static int uniphier_of_serial_setup(struct device *dev, struct uart_port *port,
OpenPOWER on IntegriCloud