core: device_bind_common: only delete U-Boot existance node
Use "u-boot,dm-pre-reloc" to identify whether the existance node is from U-Boot or not. This avoids deleting the same name nodes from kernel dtb. Change-Id: I6503965c0013053feefad7e93f98b01b5af71f44 Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This commit is contained in:
parent
039bc38d48
commit
d7a244f923
|
|
@ -69,7 +69,8 @@ static int device_bind_common(struct udevice *parent, const struct driver *drv,
|
|||
struct udevice *n;
|
||||
|
||||
list_for_each_entry_safe(dev, n, &uc->dev_head, uclass_node) {
|
||||
if (!strcmp(name, dev->name)) {
|
||||
if (!strcmp(name, dev->name) &&
|
||||
dev_read_bool(dev, "u-boot,dm-pre-reloc")) {
|
||||
if (drv->id == UCLASS_SERIAL) {
|
||||
/* Always use serial node from U-Boot dtb */
|
||||
debug("%s do not delete uboot dev: %s\n",
|
||||
|
|
|
|||
Loading…
Reference in New Issue