From 52f2d77571c8557f5871c05307ee9ab58e147fe4 Mon Sep 17 00:00:00 2001 From: Yue Du Date: Wed, 6 Sep 2017 21:55:50 -0500 Subject: StopClocks: Fence Refresh region if L3 region clock is stopped Change-Id: I9f3af62d92bc6a44d77b34d8f407f9461f749ff9 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/45767 Tested-by: FSP CI Jenkins Tested-by: Jenkins Server Tested-by: PPE CI Tested-by: Hostboot CI Reviewed-by: Christian R. Geddes Reviewed-by: ALEXANDER M. TAFT Dev-Ready: YUE DU Reviewed-by: Jennifer A. Stofer Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/45769 Reviewed-by: Hostboot Team Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Reviewed-by: Daniel M. Crowell --- .../p9/procedures/hwp/cache/p9_hcd_cache_stopclocks.C | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'src/import/chips/p9/procedures/hwp/cache') diff --git a/src/import/chips/p9/procedures/hwp/cache/p9_hcd_cache_stopclocks.C b/src/import/chips/p9/procedures/hwp/cache/p9_hcd_cache_stopclocks.C index d8b611735..7fcc8719d 100644 --- a/src/import/chips/p9/procedures/hwp/cache/p9_hcd_cache_stopclocks.C +++ b/src/import/chips/p9/procedures/hwp/cache/p9_hcd_cache_stopclocks.C @@ -76,6 +76,7 @@ p9_hcd_cache_stopclocks( fapi2::buffer l_data64; fapi2::buffer l_temp64; uint64_t l_region_clock = 0; + uint64_t l_region_fence = 0; uint64_t l_l3mask_pscom = 0; uint32_t l_loops1ms = 0; uint32_t l_scom_addr = 0; @@ -267,8 +268,23 @@ p9_hcd_cache_stopclocks( FAPI_DBG("Assert vital fence via CPLT_CTRL1[3]"); FAPI_TRY(putScom(i_target, EQ_CPLT_CTRL1_OR, MASK_SET(3))); + l_region_fence = l_region_clock; + + if (!l_is_mpipl) + { + if (l_region_fence & p9hcd::CLK_REGION_EX0_L3) + { + l_region_fence |= p9hcd::CLK_REGION_EX0_REFR; + } + + if (l_region_fence & p9hcd::CLK_REGION_EX1_L3) + { + l_region_fence |= p9hcd::CLK_REGION_EX1_REFR; + } + } + FAPI_DBG("Assert regional fences via CPLT_CTRL1[4-14]"); - FAPI_TRY(putScom(i_target, EQ_CPLT_CTRL1_OR, l_region_clock)); + FAPI_TRY(putScom(i_target, EQ_CPLT_CTRL1_OR, l_region_fence)); // Gate the PCBMux request so scanning doesn't cause random requests for(auto& it : l_core_functional_vector) -- cgit v1.2.1