]> www.infradead.org Git - users/dwmw2/linux.git/commit
KVM: arm64: Add PSCI v1.3 SYSTEM_OFF2 function for hibernation
authorDavid Woodhouse <dwmw@amazon.co.uk>
Mon, 11 Mar 2024 08:02:16 +0000 (08:02 +0000)
committerDavid Woodhouse <dwmw@amazon.co.uk>
Fri, 22 Mar 2024 17:24:22 +0000 (17:24 +0000)
commit3cad88da46c6f1f08a45aaa2201e8b2dcfda3875
tree2f1be18184b298c39b14305265ff153bb8d84ffa
parentfd38a4568c6021068d16d27c5413b1faeb4c31f7
KVM: arm64: Add PSCI v1.3 SYSTEM_OFF2 function for hibernation

The PSCI v1.3 specification (alpha) adds support for a SYSTEM_OFF2 function
which is analogous to ACPI S4 state. This will allow hosting environments
to determine that a guest is hibernated rather than just powered off, and
ensure that they preserve the virtual environment appropriately to allow
the guest to resume safely (or bump the hardware_signature in the FACS to
trigger a clean reboot instead).

The beta version will be changed to say that PSCI_FEATURES returns a bit
mask of the supported hibernate types, which is implemented here.

Although this new feature is inflicted unconditionally on unexpecting
userspace, it ought to be mostly OK because it still results in the same
KVM_SYSTEM_EVENT_SHUTDOWN event, just with a new flag which hopefully
won't cause userspace to get unhappy.

Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Documentation/virt/kvm/api.rst
arch/arm64/include/uapi/asm/kvm.h
arch/arm64/kvm/psci.c