X-Git-Url: http://git.cascardo.info/?a=blobdiff_plain;f=drivers%2Ftty%2Fserial%2Fpch_uart.c;h=d391650b82e7be9bb63ac7df85a9de3e4fe0bed8;hb=e6dce825fba05f447bd22c865e27233182ab3d79;hp=ea4ffc2ebb2fe9366da26d58b960b0c81e46553c;hpb=0dc0d9e18e7d4076440bdab73410cdfc1337586a;p=cascardo%2Flinux.git diff --git a/drivers/tty/serial/pch_uart.c b/drivers/tty/serial/pch_uart.c index ea4ffc2ebb2f..d391650b82e7 100644 --- a/drivers/tty/serial/pch_uart.c +++ b/drivers/tty/serial/pch_uart.c @@ -31,6 +31,7 @@ #include #include #include +#include #include #include @@ -1603,7 +1604,7 @@ static void pch_uart_put_poll_char(struct uart_port *port, } #endif /* CONFIG_CONSOLE_POLL */ -static struct uart_ops pch_uart_ops = { +static const struct uart_ops pch_uart_ops = { .tx_empty = pch_uart_tx_empty, .set_mctrl = pch_uart_set_mctrl, .get_mctrl = pch_uart_get_mctrl, @@ -1826,6 +1827,10 @@ static struct eg20t_port *pch_uart_init_port(struct pci_dev *pdev, priv->trigger_level = 1; priv->fcr = 0; + if (pdev->dev.of_node) + of_property_read_u32(pdev->dev.of_node, "clock-frequency" + , &user_uartclk); + #ifdef CONFIG_SERIAL_PCH_UART_CONSOLE pch_uart_ports[board->line_no] = priv; #endif