Skip to content

Commit

Permalink
Pass i_skipComm to _buildOccs
Browse files Browse the repository at this point in the history
In the _resetOccs path the i_skipComm parameter is not getting
passed into _buildOccs function that (almost) unconditionally
executes sendOccPoll, regardless of whether the comm was supposed
to be skipped or not. That 1) defeats the purpose of i_skipComm,
and 2) may not work in the OCC reset path depending on how far into
OCC setup the code has gotten before the reset was requested.

Change-Id: I044e1193d8ddf022ada902030c74c75076af2f42
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/54522
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>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Marshall J. Wilks <mjwilks@us.ibm.com>
Reviewed-by: Christopher J. Cain <cjcain@us.ibm.com>
Reviewed-by: Andres A. Lugo-Reyes <aalugore@us.ibm.com>
Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
  • Loading branch information
Ilya Smirnov authored and dcrowell77 committed Feb 23, 2018
1 parent 55e51a6 commit a681d51
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 8 deletions.
13 changes: 8 additions & 5 deletions src/usr/htmgt/htmgt_occ.C
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,8 @@ namespace HTMGT


// Query the functional OCCs and build OCC objects
errlHndl_t OccManager::_buildOccs(const bool i_occStart)
errlHndl_t OccManager::_buildOccs(const bool i_occStart,
const bool i_skipComm)
{
errlHndl_t err = nullptr;
bool safeModeNeeded = false;
Expand Down Expand Up @@ -591,7 +592,8 @@ namespace HTMGT
safeModeNeeded = true;
}

if ((false == i_occStart) && (nullptr == err))
if ((false == i_occStart) && (nullptr == err) &&
(false == i_skipComm))
{
// Send poll to query state of all OCCs
// and flush any errors reported by the OCCs
Expand Down Expand Up @@ -870,7 +872,7 @@ namespace HTMGT
errlHndl_t err = nullptr;
bool atThreshold = false;

err = _buildOccs(); // if not a already built.
err = _buildOccs(false, i_skipComm); // if not a already built.
if (nullptr == err)
{
if (false == int_flags_set(FLAG_RESET_DISABLED))
Expand Down Expand Up @@ -1502,9 +1504,10 @@ namespace HTMGT
}


errlHndl_t OccManager::buildOccs(const bool i_occStart)
errlHndl_t OccManager::buildOccs(const bool i_occStart, bool i_skipComm)
{
return Singleton<OccManager>::instance()._buildOccs(i_occStart);
return Singleton<OccManager>::instance()._buildOccs(i_occStart,
i_skipComm);
}


Expand Down
10 changes: 7 additions & 3 deletions src/usr/htmgt/htmgt_occ.H
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2014,2017 */
/* Contributors Listed Below - COPYRIGHT 2014,2018 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -453,9 +453,12 @@ namespace HTMGT
*
* @param[in] i_occStart true if call is being made after
* OCCs have just been started.
* @param[in] i_skipComm true if sendOccPoll should not
* be called
* @return NULL on success, or error handle on failure
*/
static errlHndl_t buildOccs(const bool i_occStart = false);
static errlHndl_t buildOccs(bool i_occStart = false,
bool i_skipComm = false);


/**
Expand Down Expand Up @@ -687,7 +690,8 @@ namespace HTMGT


/* See buildOccs() above */
errlHndl_t _buildOccs(const bool i_occStart = false);
errlHndl_t _buildOccs(bool i_occStart = false,
bool i_skipComm = false);


/* See getNumOccs() above */
Expand Down

0 comments on commit a681d51

Please sign in to comment.