dm: serial: bind stdout device anyway
If the console is not marked to be bound, bind it anyway. This makes serial node in U-Boot dtb no need to be enabled and bound into dm tree since they are not sured to be the stdout for pre-loader serial. This avoids the mix of kernel and U-Boot serial node under serial uclass list, otherwise serial device bound from U-Boot dtb always have the higher priority. Signed-off-by: Joseph Chen <chenjh@rock-chips.com> Change-Id: I4d35626288124d14d47df2e7492d12f1af6a36ae
This commit is contained in:
parent
02c954e505
commit
80fe0cff6f
|
|
@ -108,6 +108,18 @@ static void serial_find_console_or_panic(void)
|
|||
gd->cur_serial_dev = dev;
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
* If the console is not marked to be bound, bind it
|
||||
* anyway.
|
||||
*/
|
||||
if (!lists_bind_fdt(gd->dm_root, np_to_ofnode(np),
|
||||
&dev)) {
|
||||
if (!device_probe(dev)) {
|
||||
gd->cur_serial_dev = dev;
|
||||
return;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (!serial_check_stdout(blob, &dev)) {
|
||||
gd->cur_serial_dev = dev;
|
||||
|
|
|
|||
Loading…
Reference in New Issue