sysreset: use psci sysreset as primary for rockchip platforms
"rockchip_reset" is applied if PSCI is not enabled. Change-Id: Id219bf6d4c5d75e2b35af41b42ee0fc718800b68 Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This commit is contained in:
parent
aeed442f96
commit
bbef4bcaa1
|
|
@ -5,7 +5,9 @@
|
|||
#
|
||||
|
||||
obj-$(CONFIG_$(SPL_TPL_)SYSRESET) += sysreset-uclass.o
|
||||
ifndef CONFIG_TPL_BUILD
|
||||
obj-$(CONFIG_SYSRESET_PSCI) += sysreset_psci.o
|
||||
endif
|
||||
obj-$(CONFIG_SYSRESET_SYSCON) += sysreset_syscon.o
|
||||
obj-$(CONFIG_SYSRESET_WATCHDOG) += sysreset_watchdog.o
|
||||
|
||||
|
|
|
|||
|
|
@ -30,6 +30,20 @@ int sysreset_walk(enum sysreset_t type)
|
|||
struct udevice *dev;
|
||||
int ret = -ENOSYS;
|
||||
|
||||
/*
|
||||
* Use psci sysreset as primary for rockchip platforms,
|
||||
* "rockchip_reset" is applied if PSCI is disabled.
|
||||
*/
|
||||
#if !defined(CONFIG_TPL_BUILD) && \
|
||||
defined(CONFIG_ARCH_ROCKCHIP) && defined(CONFIG_SYSRESET_PSCI)
|
||||
ret = uclass_get_device_by_driver(UCLASS_SYSRESET,
|
||||
DM_GET_DRIVER(psci_sysreset), &dev);
|
||||
if (!ret)
|
||||
sysreset_request(dev, type);
|
||||
else
|
||||
printf("WARN: PSCI sysreset is disabled\n");
|
||||
#endif
|
||||
|
||||
while (ret != -EINPROGRESS && type < SYSRESET_COUNT) {
|
||||
for (uclass_first_device(UCLASS_SYSRESET, &dev);
|
||||
dev;
|
||||
|
|
|
|||
Loading…
Reference in New Issue