Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 66dd99c2 authored by Michal Simek's avatar Michal Simek Committed by Greg Kroah-Hartman
Browse files

tty: serial: xuartps: Setup early console when uartclk is also passed



Baudrate calculation depends on requested baudrate and uart clock.
This patch is checking that uartclk is also passed.

The same logic is used 8250_early.c/init_port function.

Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 903f9db1
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1181,7 +1181,7 @@ static int __init cdns_early_console_setup(struct earlycon_device *device,
	/* only set baud if specified on command line - otherwise
	 * assume it has been initialized by a boot loader.
	 */
	if (device->baud) {
	if (port->uartclk && device->baud) {
		u32 cd = 0, bdiv = 0;
		u32 mr;
		int div8;