doc: Update hv power management doc

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
This commit is contained in:
Yin Fengwei 2019-10-21 22:00:18 +08:00 committed by deb-intel
parent b2ef980260
commit 3a4af4b096
2 changed files with 20 additions and 20 deletions

View File

@ -8,42 +8,42 @@ System PM module
The PM module in the hypervisor does three things: The PM module in the hypervisor does three things:
- When all UOSes enter low power state, VM management will notify the SOS - Monitor all guests power state transition. And emulate low power
lifecycle service and trigger the SOS to enter a low-power state. state for the guests which are launched by HV directly.
SOS follows its own standard low-power state entry process and
writes the ACPI control register to put SOS into low-power state.
Hypervisor traps the ACPI control register writing and
emulates SOS low-power state entry.
- Once SOS low-power emulation is done, Hypervisor handles its - Once all guests enter low power state, Hypervisor handles its
own low-power state transition own low-power state transition
- Once system resumes from low-power mode, the hypervisor handles its - Once system resumes from low-power mode, the hypervisor handles its
own resume and emulates SOS resume too. own resume and emulates Service VM resume too.
It is assumed that SOS does not trigger any power state transition until It is assumed that Service VM does not trigger any power state transition
the VM manager of ACRN notifies it that all UOSes are inactive and SOS until the VM manager of ACRN notifies it that all User VMs are inactive
offlines all its virtual APs. and Service VM offlines all its virtual APs. And it is assumed that HV
does not trigger its own power state transition until all guests are in
low power state.
:numref:`pm-low-power-transition` shows the SOS/Hypervisor low-power :numref:`pm-low-power-transition` shows the Hypervisor entering S3
state transition process. SOS triggers power state transition by state process. Service VM triggers power state transition by
writing ACPI control register on its virtual BSP (which is pinned to the writing ACPI control register on its virtual BSP (which is pinned to the
physical BSP). The hypervisor then does the following in sequence before physical BSP). The hypervisor then does the following in sequence before
it writes to the physical ACPI control register to trigger physical it writes to the physical ACPI control register to trigger physical
power state transition: power state transition:
- Pauses SOS. - Pauses Service VM.
- Wait all other guests enter low power state.
- Offlines all physical APs. - Offlines all physical APs.
- Save the context of console, ioapic of SOS, I/O MMU, lapic of SOS, - Save the context of console, ioapic of Service VM, I/O MMU, lapic of
virtual BSP. Service VM, virtual BSP.
- Save the context of physical BSP. - Save the context of physical BSP.
When exiting from low-power mode, the hypervisor does similar steps in When exiting from S3 state, the hypervisor does similar steps in
reverse order to restore contexts, start APs and resume SOS. SOS is reverse order to restore contexts, start APs and resume all guests launched
responsible for starting its own virtual APs as well as UOSes. by hypervisor directly. Service VM is responsible for starting its own
virtual APs as well as User VMs.
.. figure:: images/pm-image24-105.png .. figure:: images/pm-image24-105.png
:align: center :align: center
:name: pm-low-power-transition :name: pm-low-power-transition
SOS/Hypervisor low power state transition process Service VM/Hypervisor S3 transition process

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 38 KiB