Implement the fundamentals for suspend/resume on arm64. This uses PSCI
authorkettenis <kettenis@openbsd.org>
Wed, 13 Jul 2022 09:28:18 +0000 (09:28 +0000)
committerkettenis <kettenis@openbsd.org>
Wed, 13 Jul 2022 09:28:18 +0000 (09:28 +0000)
commit4002e08df2479919957b4d3cf5ed718bd9709133
tree00644eb1152ba63e28ef6219564dc457879186e1
parent58d3804e3d7b966fbeaf18c39975886f207ef401
Implement the fundamentals for suspend/resume on arm64.  This uses PSCI
to turn off the secondary CPUs and suspend the primary CPU using the
CPU_OFF and SYSTEM_SUSPEND calls.  A new "halt" IPI is added to turn off
the ssecondary CPUs.  This IPI is implemented for the ampintc(4) and
agintc(4) interrupt controllers.  Fulle suspend/resume support is only
implemented for ampintc(4).  This is enough to suspend and resume boards
based on the Allwinner A64 SoC, provided the necessary wakeup interrupts
have been set up (not part of this commit).

ok patrick@
sys/arch/arm64/arm64/cpu.c
sys/arch/arm64/arm64/genassym.cf
sys/arch/arm64/arm64/locore.S
sys/arch/arm64/conf/GENERIC
sys/arch/arm64/dev/agintc.c
sys/arch/arm64/dev/ampintc.c
sys/arch/arm64/dev/aplintc.c
sys/arch/arm64/dev/apm.c
sys/arch/arm64/include/cpu.h
sys/arch/arm64/include/intr.h