summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf
diff options
context:
space:
mode:
Diffstat (limited to 'src/usr/hwpf')
-rw-r--r--src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C38
1 files changed, 37 insertions, 1 deletions
diff --git a/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C
index b749919a8..57451cb4a 100644
--- a/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C
+++ b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C
@@ -71,6 +71,12 @@ const uint64_t CENTAUR_SBE_PNOR_MRR = 0;
// Max SBE image buffer size
const uint32_t MAX_SBE_IMG_SIZE = 48 * 1024;
+// Low MSS freq for 32x32 machines
+const uint32_t MSS_FREQ_32x32_CONFIG = 1066;
+
+// Low Nest Freq
+const uint32_t LOW_NEST_FREQ = 2000;
+
namespace SBE_CENTAUR_INIT
{
@@ -95,9 +101,16 @@ void* call_sbe_centaur_init( void *io_pArgs )
TARGETING::TargetHandleList l_membufTargetList;
getAllChips(l_membufTargetList, TYPE_MEMBUF);
+ // Get sys target to check capable nest frequencies
+ TARGETING::Target* l_sys = NULL;
+ targetService().getTopLevelTarget(l_sys);
+ assert(l_sys != NULL, "sbe_centaur_init: sys target is NULL");
+
size_t l_sbePnorSize = 0;
void* l_sbePnorAddr = NULL;
errlHndl_t l_errl = NULL;
+ uint32_t l_booted_nest_freq = 0;
+ MRW_NEST_CAPABLE_FREQUENCIES_SYS l_mrw_nest_capable;
IStepError l_StepError;
@@ -213,8 +226,31 @@ void* call_sbe_centaur_init( void *io_pArgs )
// XIP customize is going to look for a PLL ring with a "stub"
// mem freq -- so set to a default, then clear it (so as not
// to mess up MSS HWP later
- l_membuf_target->setAttr<TARGETING::ATTR_MSS_FREQ>(1600);
+ // Grab capable frequencies
+ l_mrw_nest_capable =
+ l_sys->getAttr<ATTR_MRW_NEST_CAPABLE_FREQUENCIES_SYS>();
+
+ // Get the nest freq we booted with
+ l_booted_nest_freq = l_sys->getAttr<TARGETING::ATTR_NEST_FREQ_MHZ>();
+
+ // If we are running nest at 2.0, and we support 2.0 and 2.4, we
+ // need to drop MSS freq to 1066
+ if ((l_mrw_nest_capable ==
+ MRW_NEST_CAPABLE_FREQUENCIES_SYS_2000_MHZ_OR_2400_MHZ) &&
+ (l_booted_nest_freq == LOW_NEST_FREQ))
+ {
+ TRACFCOMP(ISTEPS_TRACE::g_trac_isteps_trace,
+ "Reducing MSS frequency in sbe_centaur_init to %d based on "
+ "nest frequency", MSS_FREQ_32x32_CONFIG);
+
+ l_membuf_target->setAttr
+ <TARGETING::ATTR_MSS_FREQ>(MSS_FREQ_32x32_CONFIG);
+ }
+ else //boot as normal
+ {
+ l_membuf_target->setAttr<TARGETING::ATTR_MSS_FREQ>(1600);
+ }
FAPI_INVOKE_HWP( l_errl, cen_xip_customize,
l_fapiTarget, l_sbePnorAddr,
OpenPOWER on IntegriCloud