diff options
| author | Prachi Gupta <pragupta@us.ibm.com> | 2018-05-21 15:29:40 -0500 |
|---|---|---|
| committer | William G. Hoffa <wghoffa@us.ibm.com> | 2018-06-02 11:59:58 -0400 |
| commit | 5815703c3be9f8830011f573a719e69553cb1b94 (patch) | |
| tree | 46a7c93cb82a1736d52c7bef338519a444724677 /src/include/usr | |
| parent | c6916a42d34bdd1c9502056740ec3a819c082099 (diff) | |
| download | talos-hostboot-5815703c3be9f8830011f573a719e69553cb1b94.tar.gz talos-hostboot-5815703c3be9f8830011f573a719e69553cb1b94.zip | |
Add support for missing memory behind master proc
On a phyp based system, when we detect that memory is missing
behind master processor, we find a proc with memory and set
ATTR_PROC_MEM_TO_USE to its HRMOR. This commit adds this support
in hwas common code as HWSV will call this function, update SBE
mbox registers, and IPL the system.
Change-Id: I88a6cb69aa10147365c556f9cf31014066bd3d08
CQ:SW430015
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/59159
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Reviewed-by: Sachin Gupta <sgupta2m@in.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Diffstat (limited to 'src/include/usr')
| -rw-r--r-- | src/include/usr/hwas/common/hwas.H | 40 | ||||
| -rw-r--r-- | src/include/usr/hwas/common/hwas_reasoncodes.H | 16 |
2 files changed, 48 insertions, 8 deletions
diff --git a/src/include/usr/hwas/common/hwas.H b/src/include/usr/hwas/common/hwas.H index 7289b8ecb..06304c29c 100644 --- a/src/include/usr/hwas/common/hwas.H +++ b/src/include/usr/hwas/common/hwas.H @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2012,2017 */ +/* Contributors Listed Below - COPYRIGHT 2012,2018 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -221,6 +221,44 @@ void calculateEffectiveEC(); */ errlHndl_t markDisabledMcas(); + +/* + * @brief: This function calls check_for_missing_memory and set + * ATTR_PROC_MEM_TO_USE to the processor that we should use + * in case of missing memory behind master proc + * + * @note: Only applicable for PHYP based system + * + * @param[in]: i_node: Node target to operate on + * + * @retval: error log handle + */ +errlHndl_t update_proc_mem_to_use (const TARGETING::Target* i_node); + +/* + * @brief: checks whether we are missing memory behind master proc + * + * If there is no memory behind the master proc, then we iterate + * through all the other procs and figure out a proc that has + * memory. We figure out the proc with memory and + * return that to the user as io_proc_mem_to_use. User can update + * ATTR_PROC_MEM_TO_USE as needed. + * + * @note: Only applicable for PHYP based system + * + * @param[in]: i_node: Node target to operate on + * @param[in/out]: io_proc_mem_to_use: Value of ATTR_PROC_MEM_TO_USE + * the value is changed only if we find missing + * memory + * @param[out]: o_found_missing_mem: indicated whether we found missing + * memory behind master proc or not + * @retval error log handle + */ +errlHndl_t check_for_missing_memory (const TARGETING::Target* i_node, + uint8_t & io_proc_mem_to_use, + bool & o_found_missing_mem); + + }; // end namespace #endif diff --git a/src/include/usr/hwas/common/hwas_reasoncodes.H b/src/include/usr/hwas/common/hwas_reasoncodes.H index 94248a5d4..c81904c6d 100644 --- a/src/include/usr/hwas/common/hwas_reasoncodes.H +++ b/src/include/usr/hwas/common/hwas_reasoncodes.H @@ -29,13 +29,14 @@ namespace HWAS { enum HwasModuleID { - MOD_DECONFIG_GARD = 0x01, - MOD_PROCESS_CALLOUT = 0x02, - MOD_CHECK_MIN_HW = 0x03, - MOD_DECONFIG_TARGETS_FROM_GARD = 0x04, - MOD_VALIDATE_EC_LEVELS = 0x05, - MOD_RUNTIME_DECONFIG = 0x06, - MOD_DISABLE_OBUS = 0x07, + MOD_DECONFIG_GARD = 0x01, + MOD_PROCESS_CALLOUT = 0x02, + MOD_CHECK_MIN_HW = 0x03, + MOD_DECONFIG_TARGETS_FROM_GARD = 0x04, + MOD_VALIDATE_EC_LEVELS = 0x05, + MOD_RUNTIME_DECONFIG = 0x06, + MOD_DISABLE_OBUS = 0x07, + MOD_UPDATE_PROC_MEM_TO_USE = 0x08, }; enum HwasReasonCode @@ -64,6 +65,7 @@ namespace HWAS RC_NOT_AT_RUNTIME = HWAS_COMP_ID | 0x12, RC_NULL_TARGET = HWAS_COMP_ID | 0x13, RC_ONLY_TWO_OBUS_SHOULD_BE_CONFIGURED = HWAS_COMP_ID | 0x14, + RC_NO_UPDATE_WHEN_MEM_MISSING = HWAS_COMP_ID | 0x15, }; }; |

