From 1f1e263edc891398fabb3ac18c609198419ef2b7 Mon Sep 17 00:00:00 2001 From: Brian Stegmiller Date: Thu, 21 Jul 2016 15:25:02 -0500 Subject: Limit checkForIplAttentions to master in early IPL Change-Id: I74f3c6c00fdb7ea30bdf06d4be37c1a717fc6210 RTC: 154658 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/27342 Tested-by: Jenkins Server Tested-by: FSP CI Jenkins Reviewed-by: Daniel M. Crowell --- src/usr/diag/attn/ipl/attn.C | 37 ++++++++- .../initservice/istepdispatcher/istepdispatcher.C | 6 +- src/usr/isteps/istep08/call_host_attnlisten_proc.C | 91 ++++++++++++++++++++++ src/usr/isteps/istep08/makefile | 1 + .../common/xmltohb/attribute_types_hb.xml | 14 ++++ .../targeting/common/xmltohb/target_types_hb.xml | 1 + 6 files changed, 144 insertions(+), 6 deletions(-) create mode 100644 src/usr/isteps/istep08/call_host_attnlisten_proc.C (limited to 'src/usr') diff --git a/src/usr/diag/attn/ipl/attn.C b/src/usr/diag/attn/ipl/attn.C index 8e5543e74..dac127d56 100644 --- a/src/usr/diag/attn/ipl/attn.C +++ b/src/usr/diag/attn/ipl/attn.C @@ -39,6 +39,7 @@ #include "common/attnmem.H" #include #include +#include // Custom compile configs #include @@ -72,9 +73,41 @@ errlHndl_t checkForIplAttentions() assert(!Singleton::instance().running()); - TargetHandleList list; + TargetHandleList list; + uint8_t l_useAllProcs = 0; + TARGETING::Target *l_MasterProcTarget = NULL; + TARGETING::Target *l_sys = NULL; + + + // ------------------------------------------------ + // NOTE: ATTN code overrides TARGETING code for + // testing purposes. However for this case + // of getting an attribute, we can just + // modify the attribute for testing. + // For the master proc, I don't think we + // really need to alter it for testing. + // ------------------------------------------------ + + // We have an ATTRIBUTE that indicates all procs + // or just the master proc. + TARGETING::targetService().getTopLevelTarget( l_sys ); + assert(l_sys != NULL); + l_sys->tryGetAttr(l_useAllProcs); + + + // Do we want to check ALL procs ? + if (0 == l_useAllProcs) + { + // Just the master (so early IPL) + TARGETING::targetService().masterProcChipTargetHandle( + l_MasterProcTarget); + list.push_back(l_MasterProcTarget); + } // end if just master proc + else + { + getTargetService().getAllChips(list, TYPE_PROC); + } // end else ALL procs - getTargetService().getAllChips(list, TYPE_PROC); TargetHandleList::iterator tit = list.begin(); diff --git a/src/usr/initservice/istepdispatcher/istepdispatcher.C b/src/usr/initservice/istepdispatcher/istepdispatcher.C index 852907226..c8c9de7de 100644 --- a/src/usr/initservice/istepdispatcher/istepdispatcher.C +++ b/src/usr/initservice/istepdispatcher/istepdispatcher.C @@ -756,9 +756,7 @@ errlHndl_t IStepDispatcher::doIstep(uint32_t i_istep, TRACFCOMP(g_trac_initsvc, ERR_MRK"doIstep: Istep failed, plid 0x%x", err->plid()); } - // @TODO-RTC:154658 Re-enable this once new slave proc attn - // handling is done. -#if 0 + // Check for any attentions and invoke PRD for analysis // if not in MPIPL mode else if ((true == theStep->taskflags.check_attn) && @@ -775,7 +773,7 @@ errlHndl_t IStepDispatcher::doIstep(uint32_t i_istep, "checkForIplAttentions"); } } -#endif + #ifdef CONFIG_RECONFIG_LOOP_TESTS_ENABLE // Read ATTR_RECONFIG_LOOP_TESTS_ENABLE attribute TARGETING::ATTR_RECONFIG_LOOP_TESTS_ENABLE_type l_reconfigAttrTestsEn = diff --git a/src/usr/isteps/istep08/call_host_attnlisten_proc.C b/src/usr/isteps/istep08/call_host_attnlisten_proc.C new file mode 100644 index 000000000..455b95837 --- /dev/null +++ b/src/usr/isteps/istep08/call_host_attnlisten_proc.C @@ -0,0 +1,91 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/usr/isteps/istep08/call_host_attnlisten_proc.C $ */ +/* */ +/* OpenPOWER HostBoot Project */ +/* */ +/* Contributors Listed Below - COPYRIGHT 2016 */ +/* [+] International Business Machines Corp. */ +/* */ +/* */ +/* Licensed under the Apache License, Version 2.0 (the "License"); */ +/* you may not use this file except in compliance with the License. */ +/* You may obtain a copy of the License at */ +/* */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* Unless required by applicable law or agreed to in writing, software */ +/* distributed under the License is distributed on an "AS IS" BASIS, */ +/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */ +/* implied. See the License for the specific language governing */ +/* permissions and limitations under the License. */ +/* */ +/* IBM_PROLOG_END_TAG */ +/** + * @file call_host_attnlisten_proc.C + * + * Support file for IStep: host_attnlisten_proc + * + * HWP_IGNORE_VERSION_CHECK + */ + +/******************************************************************************/ +// Includes +/******************************************************************************/ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// targeting support +#include +#include +#include +#include + +#include + +#include +#include + +using namespace ISTEP; +using namespace ISTEP_ERROR; +using namespace ERRORLOG; +using namespace TARGETING; + +namespace ISTEP_08 +{ + +//****************************************************************************** +// call_host_attnlisten_proc() +//****************************************************************************** +void* call_host_attnlisten_proc(void *io_pArgs) +{ + IStepError l_stepError; + + + TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, + "call_host_attnlisten_proc entry" ); + + uint8_t l_useAllProcs = 1; + TARGETING::Target *l_sys = NULL; + TARGETING::targetService().getTopLevelTarget( l_sys ); + assert(l_sys != NULL); + + // All we need to do is set a flag so that the + // ATTN code will check ALL processors the next + // time it gets called versus just the master proc. + l_sys->trySetAttr(l_useAllProcs); + + TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, + "call_host_attnlisten_proc exit" ); + return l_stepError.getErrorHandle(); +} + +}; diff --git a/src/usr/isteps/istep08/makefile b/src/usr/isteps/istep08/makefile index da41c61bf..17a881ed4 100644 --- a/src/usr/isteps/istep08/makefile +++ b/src/usr/isteps/istep08/makefile @@ -60,6 +60,7 @@ OBJS += call_proc_scomoverride_chiplets.o OBJS += call_proc_chiplet_enable_ridi.o OBJS += call_host_rng_bist.o OBJS += call_host_set_voltages.o +OBJS += call_host_attnlisten_proc.o VPATH += ${PROCEDURES_PATH}/hwp/perv/ ${PROCEDURES_PATH}/hwp/nest/ VPATH += ${PROCEDURES_PATH}/hwp/io/ ${PROCEDURES_PATH}/hwp/initfiles/ diff --git a/src/usr/targeting/common/xmltohb/attribute_types_hb.xml b/src/usr/targeting/common/xmltohb/attribute_types_hb.xml index 492a7a407..d2006d5e8 100644 --- a/src/usr/targeting/common/xmltohb/attribute_types_hb.xml +++ b/src/usr/targeting/common/xmltohb/attribute_types_hb.xml @@ -1705,4 +1705,18 @@ ID for the sensor number returned with the elog. --> + + ATTN_CHK_ALL_PROCS + + Used to tell ATTN code whether to chk MASTER(0) OR all PROCs(1) + when the checkForIplAttns routine is called. + + + + + volatile-zeroed + + + + diff --git a/src/usr/targeting/common/xmltohb/target_types_hb.xml b/src/usr/targeting/common/xmltohb/target_types_hb.xml index 63e870a6c..206fd3134 100755 --- a/src/usr/targeting/common/xmltohb/target_types_hb.xml +++ b/src/usr/targeting/common/xmltohb/target_types_hb.xml @@ -79,6 +79,7 @@ IPMI_MAX_BUFFER_SIZE CLEAR_DIMM_SPD_ENABLE OCC_COMMON_AREA_PHYS_ADDR + ATTN_CHK_ALL_PROCS -- cgit v1.2.1