[Skiboot] [RFC 0/4] Enable stop4 idle state

Akshay Adiga akshay.adiga at linux.vnet.ibm.com
Thu May 4 17:16:43 AEST 2017


The following patch series enabled the infrastructure to support deeper
idle states like STOP4 and STOP11 on POWER9 platform.

When cpu enters stop4 or deeper state it losses few critical hypervisor
sprs. In the POWER9 platform stop-api provides interface for opal to call
into low level platform firmware/microcode to configure and setup various
actions on wakeup from deep idle state. 

Some SPRs that have implicit value like HRMOR are directly set from
OPAL, while other are left to be configured from Linux using opal
calls.

p9 stop api is used to restore these hypervisor sprs with
correct values. Sprs like HRMOR is configured from skiboot,
where as LPCR, HID and MSR are configured by kernel. Kernel
uses opal_slw_set_reg() to configure these sprs.

Integration of stop-api framework from hostboot require few header
and definitions to be resolved, and hence this patch depends on 
"[RFC] Add support for glibc style endianess detection
https://patchwork.ozlabs.org/patch/758189/

Patch 1: Add p9_stop_api from hostboot code.
Patch 2: Enable  opal_slw_set_reg() for power9
Patch 3: Configure HRMOR restore
Patch 4: Expose stop4 in device-tree as a idle state with stateloss

Akshay Adiga (4):
  SLW: Add support for p9_stop_api
  SLW: Add opal_slw_set_reg support for power9
  SLW: Configure self-restore for HRMOR
  SLW: Enable Stop4 as the deepest idle state

 hw/slw.c                                 |  114 +++-
 include/p9_stop_api.H                    |  163 +++++
 libpore/Makefile.inc                     |    2 +-
 libpore/p9_cpu_reg_restore_instruction.H |   76 +++
 libpore/p9_hcd_header_defs.H             |  152 +++++
 libpore/p9_hcd_memmap_base.H             |  503 ++++++++++++++
 libpore/p9_stop_api.C                    | 1042 ++++++++++++++++++++++++++++++
 libpore/p9_stop_api.H                    |  163 +++++
 libpore/p9_stop_data_struct.H            |  149 +++++
 libpore/p9_stop_util.C                   |  182 ++++++
 libpore/p9_stop_util.H                   |  145 +++++
 11 files changed, 2667 insertions(+), 24 deletions(-)
 create mode 100755 include/p9_stop_api.H
 create mode 100755 libpore/p9_cpu_reg_restore_instruction.H
 create mode 100644 libpore/p9_hcd_header_defs.H
 create mode 100644 libpore/p9_hcd_memmap_base.H
 create mode 100755 libpore/p9_stop_api.C
 create mode 100755 libpore/p9_stop_api.H
 create mode 100755 libpore/p9_stop_data_struct.H
 create mode 100755 libpore/p9_stop_util.C
 create mode 100755 libpore/p9_stop_util.H

-- 
2.5.5



More information about the Skiboot mailing list