David Engraf cb47b9f863 tty/serial: atmel: fix out of range clock divider handling
Use MCK_DIV8 when the clock divider is > 65535. Unfortunately the mode
register was already written thus the clock selection is ignored.

Fix by doing the baud rate calulation before setting the mode.

Fixes: 5bf5635ac170 ("tty/serial: atmel: add fractional baud rate support")
Signed-off-by: David Engraf <david.engraf@sysgo.com>
Acked-by: Ludovic Desroches <ludovic.desroches@microchip.com>
Acked-by: Richard Genoud <richard.genoud@gmail.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20191216085403.17050-1-david.engraf@sysgo.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-12-17 14:17:32 +01:00
..
2019-12-03 14:09:14 -08:00
2019-11-13 19:01:14 +08:00
2019-04-16 15:21:34 +02:00
2018-10-13 00:50:32 -04:00
2017-11-28 15:32:33 +01:00
2018-10-13 00:50:32 -04:00
2019-10-04 15:14:20 +02:00
2017-11-08 13:08:12 +01:00
2019-09-04 12:43:44 +02:00
2019-11-04 17:42:28 +01:00
2019-02-12 08:51:33 +01:00
2019-05-14 19:52:51 -07:00
2019-12-03 14:09:14 -08:00
2019-04-16 15:21:34 +02:00