Skip to content

Commit

Permalink
PM HWP: Fixed error path bug pertaining to query STOP state.
Browse files Browse the repository at this point in the history
If HWP fails to scom core or cache clock status register, it
appropriately initiatlizes the data structs and attributes to
correctly reflect the hardware state as known at the point of
failure.
Key_Cronus_Test=PM_REGRESS

Change-Id: I585277fcc475f074a5db45b5aa1f1517e0ca2531
CQ: SW455632
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70790
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: HWSV CI <hwsv-ci+hostboot@us.ibm.com>
Tested-by: Cronus HW CI <cronushw-ci+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: RANGANATHPRASAD G. BRAHMASAMUDRA <prasadbgr@in.ibm.com>
Reviewed-by: Gregory S. Still <stillgs@us.ibm.com>
Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70812
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>
  • Loading branch information
premsjha authored and dcrowell77 committed Feb 22, 2019
1 parent 5885d18 commit ab41d47
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions src/import/chips/p9/procedures/hwp/pm/p9_query_stop_state.C
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2016,2018 */
/* Contributors Listed Below - COPYRIGHT 2016,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -369,12 +369,12 @@ query_stop_state(
FAPI_INF( "Failed to read EQ_CLOCK_STAT_SL" );
//We can't determine L2 and L3 clock state. So, let us prevent
//read from ex in question to prevent any further error.
l_clk_pfet.l2_hasclocks = 0;
l_clk_pfet.l3_hasclocks = 0;
l_clk_pfet.c_exec_hasclocks[0] = 0;
l_clk_pfet.c_exec_hasclocks[1] = 0;
l_clk_pfet.c_pc_hasclocks[0] = 0;
l_clk_pfet.c_pc_hasclocks[1] = 0;
o_stop_attrs.l2_hasclocks = 0;
o_stop_attrs.l3_hasclocks = 0;
o_stop_attrs.c0_exec_hasclocks = 0;
o_stop_attrs.c1_exec_hasclocks = 0;
o_stop_attrs.c0_pc_hasclocks = 0;
o_stop_attrs.c1_pc_hasclocks = 0;
fapi2::current_err = fapi2::RC_QUAD_CLOCK_STATUS_READ_FAIL;
goto fapi_try_exit;
}
Expand Down Expand Up @@ -408,9 +408,11 @@ query_stop_state(
if( l_tempRc )
{
FAPI_INF( "Error reading data from C_CLOCK_STAT_SL" );
l_clk_pfet.c_exec_hasclocks[l_pos] = 0;
l_clk_pfet.c_pc_hasclocks[l_pos] = 0;
fapi2::current_err = fapi2::RC_CORE_CLOCK_STATUS_READ_FAIL;
o_stop_attrs.c0_exec_hasclocks = 0;
o_stop_attrs.c1_exec_hasclocks = 0;
o_stop_attrs.c0_pc_hasclocks = 0;
o_stop_attrs.c1_pc_hasclocks = 0;
fapi2::current_err = fapi2::RC_CORE_CLOCK_STATUS_READ_FAIL;
goto fapi_try_exit;
}

Expand Down

0 comments on commit ab41d47

Please sign in to comment.