summaryrefslogtreecommitdiffstats
path: root/sys/dev/uart/uart_dev_quicc.c
diff options
context:
space:
mode:
authorandrew <andrew@FreeBSD.org>2015-04-11 17:16:23 +0000
committerandrew <andrew@FreeBSD.org>2015-04-11 17:16:23 +0000
commite2a65d5cfa2a52472daa9b9658f4fa10f742291f (patch)
tree3242f4dc9f4677a166d03c3acecc2475385f4f3d /sys/dev/uart/uart_dev_quicc.c
parent7f65d178b4fad420cb01a2ff4b3163278d3025dc (diff)
downloadFreeBSD-src-e2a65d5cfa2a52472daa9b9658f4fa10f742291f.zip
FreeBSD-src-e2a65d5cfa2a52472daa9b9658f4fa10f742291f.tar.gz
Add support for the uart classes to set their default register shift value.
This is needed with the pl011 driver. Before this change it would default to a shift of 0, however the hardware places the registers at 4-byte addresses meaning the value should be 2. This patch fixes this for the pl011 when configured using the fdt. The other drivers have a default value of 0 to keep this a no-op. MFC after: 1 week
Diffstat (limited to 'sys/dev/uart/uart_dev_quicc.c')
-rw-r--r--sys/dev/uart/uart_dev_quicc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/uart/uart_dev_quicc.c b/sys/dev/uart/uart_dev_quicc.c
index bbbc3bd..0237d64 100644
--- a/sys/dev/uart/uart_dev_quicc.c
+++ b/sys/dev/uart/uart_dev_quicc.c
@@ -271,7 +271,8 @@ struct uart_class uart_quicc_class = {
sizeof(struct quicc_softc),
.uc_ops = &uart_quicc_ops,
.uc_range = 2,
- .uc_rclk = DEFAULT_RCLK
+ .uc_rclk = DEFAULT_RCLK,
+ .uc_rshift = 0
};
#define SIGCHG(c, i, s, d) \
OpenPOWER on IntegriCloud