diff options
Diffstat (limited to 'sys/dev/uart/uart_dev_ns8250.c')
-rw-r--r-- | sys/dev/uart/uart_dev_ns8250.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/uart/uart_dev_ns8250.c b/sys/dev/uart/uart_dev_ns8250.c index 4262f8d..8e6177b 100644 --- a/sys/dev/uart/uart_dev_ns8250.c +++ b/sys/dev/uart/uart_dev_ns8250.c @@ -81,7 +81,9 @@ ns8250_delay(struct uart_bas *bas) uart_barrier(bas); /* 1/10th the time to transmit 1 character (estimate). */ - return (16000000 * divisor / bas->rclk); + if (divisor <= 134) + return (16000000 * divisor / bas->rclk); + return (16000 * divisor / (bas->rclk / 1000)); } static int |