@@ -2618,8 +2618,6 @@ static unsigned int serial8250_get_baud_rate(struct uart_port *port,
struct ktermios *termios,
struct ktermios *old)
{
- unsigned int tolerance = port->uartclk / 100;
-
/*
* Ask the core to calculate the divisor for us.
* Allow 1% tolerance at the upper limit so uart clks marginally
@@ -2628,7 +2626,7 @@ static unsigned int serial8250_get_baud_rate(struct uart_port *port,
*/
return uart_get_baud_rate(port, termios, old,
port->uartclk / 16 / UART_DIV_MAX,
- (port->uartclk + tolerance) / 16);
+ port->uartclk);
}
void
This reverts commit 0eeaf62981ecc79e8395ca8caa1570eaf3a12257. The change regresses the QCA6174A-3 bluetooth chip, preventing firmware from being properly loaded. We have verified that without this patch, the chip works as intended. Signed-off-by: Daniel Winkler <danielwinkler@google.com> --- drivers/tty/serial/8250/8250_port.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)