[PATCH] bus: ti-sysc: fix uclass driver id
Dario Binacchi
dariobin at libero.it
Mon Mar 15 22:18:39 CET 2021
The module defines a duplicate uclass driver for UCLASS_SIMPLE_BUS, but
it is not allowed. This breaks of-platdata and makes the result
non-deterministic.
Since it must be an uclass driver to work properly, a new class id has
been added.
Signed-off-by: Dario Binacchi <dariobin at libero.it>
---
drivers/bus/ti-sysc.c | 4 ++--
include/dm/uclass-id.h | 1 +
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/bus/ti-sysc.c b/drivers/bus/ti-sysc.c
index 4e3d610300..2d6bef02ba 100644
--- a/drivers/bus/ti-sysc.c
+++ b/drivers/bus/ti-sysc.c
@@ -149,14 +149,14 @@ clocks_err:
}
UCLASS_DRIVER(ti_sysc) = {
- .id = UCLASS_SIMPLE_BUS,
+ .id = UCLASS_SYSC,
.name = "ti_sysc",
.post_bind = dm_scan_fdt_dev
};
U_BOOT_DRIVER(ti_sysc) = {
.name = "ti_sysc",
- .id = UCLASS_SIMPLE_BUS,
+ .id = UCLASS_SYSC,
.of_match = ti_sysc_ids,
.probe = ti_sysc_probe,
.remove = ti_sysc_remove,
diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h
index d75de368c5..1161d2032a 100644
--- a/include/dm/uclass-id.h
+++ b/include/dm/uclass-id.h
@@ -107,6 +107,7 @@ enum uclass_id {
UCLASS_SPI_FLASH, /* SPI flash */
UCLASS_SPI_GENERIC, /* Generic SPI flash target */
UCLASS_SPMI, /* System Power Management Interface bus */
+ UCLASS_SYSC, /* TI sysc interconnect target bus */
UCLASS_SYSCON, /* System configuration device */
UCLASS_SYSINFO, /* Device information from hardware */
UCLASS_SYSRESET, /* System reset device */
--
2.17.1
More information about the U-Boot
mailing list