[PATCH v4 0/3] riscv: enable SBI system reset
Heinrich Schuchardt
heinrich.schuchardt at canonical.com
Thu Sep 9 15:11:32 CEST 2021
With SBI v0.3 a system reset extension is available. This allows to
implement reboot and poweroff in U-Boot in a system independent way.
* Provide missing constants
* Provide a system reset driver using the system reset extension.
v4:
* remove the UEFI SystemReset() implementation
* simplify the code using an array to translate reset types
* remove a superfluos check to determine if the device was probed
v3:
add SBI_HSM_HART_STATUS_SUSPENDED,
SBI_HSM_HART_STATUS_SUSPEND_PENDING,
SBI_HSM_HART_STATUS_RESUME_PENDING
v2:
correct constants that were blindly copied from Linux
Heinrich Schuchardt (3):
riscv: add missing SBI extension definitions
cmd/sbi: use constants instead of numerical values
sysreset: provide SBI based sysreset driver
MAINTAINERS | 1 +
arch/riscv/cpu/cpu.c | 13 ++++++++-
arch/riscv/include/asm/sbi.h | 40 ++++++++++++++++++++++++--
arch/riscv/lib/sbi.c | 21 +++++++++++---
cmd/riscv/sbi.c | 30 +++++++++----------
drivers/sysreset/Kconfig | 12 ++++++++
drivers/sysreset/Makefile | 1 +
drivers/sysreset/sysreset_sbi.c | 51 +++++++++++++++++++++++++++++++++
8 files changed, 147 insertions(+), 22 deletions(-)
create mode 100644 drivers/sysreset/sysreset_sbi.c
--
2.30.2
More information about the U-Boot
mailing list