mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
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: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
903f9db10f
commit
66dd99c203
1 changed files with 1 additions and 1 deletions
|
@ -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;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue