From ea6d83f002e29a33dfb8c5ff07bfd1f5312893a0 Mon Sep 17 00:00:00 2001 From: Koen Kooi Date: Tue, 21 Aug 2007 16:36:38 +0000 Subject: linux 2.6.21: add gumstix support --- packages/linux/linux-2.6.21/serial-divisor.patch | 31 ++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 packages/linux/linux-2.6.21/serial-divisor.patch (limited to 'packages/linux/linux-2.6.21/serial-divisor.patch') diff --git a/packages/linux/linux-2.6.21/serial-divisor.patch b/packages/linux/linux-2.6.21/serial-divisor.patch new file mode 100644 index 0000000000..efce5a51ef --- /dev/null +++ b/packages/linux/linux-2.6.21/serial-divisor.patch @@ -0,0 +1,31 @@ +Index: linux-2.6.21gum/drivers/serial/pxa.c +=================================================================== +--- linux-2.6.21gum.orig/drivers/serial/pxa.c ++++ linux-2.6.21gum/drivers/serial/pxa.c +@@ -41,6 +41,7 @@ + #include + #include + #include ++#include + #include + + #include +@@ -577,8 +578,16 @@ static void serial_pxa_config_port(struc + static int + serial_pxa_verify_port(struct uart_port *port, struct serial_struct *ser) + { +- /* we don't want the core code to modify any port params */ +- return -EINVAL; ++ struct uart_pxa_port *up = (struct uart_pxa_port *)port; ++ int ret = 0; ++ ++ if (up->port.uartclk / 16 != ser->baud_base) ++ ret = -EINVAL; ++ else if (((up->port.line & 1) == 0) && ser->baud_base > 230400) /* Max baud rate for STUART and FFUART */ ++ ret = -EINVAL; ++ else if (((up->port.line & 1) != 0) && ser->baud_base > 921600) /* Max baud rate for HWUART and BTUART */ ++ ret = -EINVAL; ++ return ret; + } + + static const char * -- cgit v1.2.3