diff options
Diffstat (limited to 'drivers/core')
-rw-r--r-- | drivers/core/Kconfig | 2 | ||||
-rw-r--r-- | drivers/core/acpi.c | 4 | ||||
-rw-r--r-- | drivers/core/lists.c | 15 |
3 files changed, 13 insertions, 8 deletions
diff --git a/drivers/core/Kconfig b/drivers/core/Kconfig index 8eb0070d22..007dc6a1de 100644 --- a/drivers/core/Kconfig +++ b/drivers/core/Kconfig @@ -18,7 +18,7 @@ config SPL_DM consider using CONFIG_SPL_SYS_MALLOC_SIMPLE. In that case you must provide CONFIG_SPL_SYS_MALLOC_F_LEN to set the size. In most cases driver model will only allocate a few uclasses - and devices in SPL, so 1KB should be enable. See + and devices in SPL, so 1KB should be enough. See CONFIG_SPL_SYS_MALLOC_F_LEN for more details on how to enable it. config TPL_DM diff --git a/drivers/core/acpi.c b/drivers/core/acpi.c index 0df58dbc0d..8457733edb 100644 --- a/drivers/core/acpi.c +++ b/drivers/core/acpi.c @@ -159,8 +159,8 @@ static int add_item(struct acpi_ctx *ctx, struct udevice *dev, memcpy(item->buf, start, item->size); } item_count++; - log_debug("* %s: Added type %d, %p, size %x\n", dev->name, type, start, - item->size); + log_debug("* %s: Added type %d, %p, size %x\n", + dev ? dev->name : "other", type, start, item->size); return 0; } diff --git a/drivers/core/lists.c b/drivers/core/lists.c index 22ccd9faaa..c49695b24f 100644 --- a/drivers/core/lists.c +++ b/drivers/core/lists.c @@ -223,10 +223,14 @@ int lists_bind_fdt(struct udevice *parent, ofnode node, struct udevice **devp, compat); for (entry = driver; entry != driver + n_ents; entry++) { + if (drv) { + if (drv != entry) + continue; + if (!entry->of_match) + break; + } ret = driver_check_compatible(entry->of_match, &id, compat); - if ((drv) && (drv == entry)) - break; if (!ret) break; } @@ -241,9 +245,10 @@ int lists_bind_fdt(struct udevice *parent, ofnode node, struct udevice **devp, } } - log_debug(" - found match at '%s': '%s' matches '%s'\n", - entry->name, entry->of_match->compatible, - id->compatible); + if (entry->of_match) + log_debug(" - found match at '%s': '%s' matches '%s'\n", + entry->name, entry->of_match->compatible, + id->compatible); ret = device_bind_with_driver_data(parent, entry, name, id->data, node, &dev); if (ret == -ENODEV) { |