summaryrefslogtreecommitdiffstats
path: root/src/import/chips/p9/initfiles
diff options
context:
space:
mode:
authorBrian Silver <bsilver@us.ibm.com>2016-10-05 16:55:56 -0500
committerDaniel M. Crowell <dcrowell@us.ibm.com>2016-10-10 13:53:42 -0400
commit105e2057c8dba73c0ef601ddf862ce27f9aedd4a (patch)
tree459976122d66e302752d50023cf83e5b66584a72 /src/import/chips/p9/initfiles
parent419fc706cfb77f1a67ff974ff84090fc6032fec3 (diff)
downloadtalos-hostboot-105e2057c8dba73c0ef601ddf862ce27f9aedd4a.tar.gz
talos-hostboot-105e2057c8dba73c0ef601ddf862ce27f9aedd4a.zip
Change MCA initfile to not divide by 0 if there are no DIMM
Change-Id: I5ebcb11dba0c77d1bf9c107dd8e3e412ca3632ce Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/30761 Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com> Reviewed-by: Jenny Huynh <jhuynh@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-by: Prachi Gupta <pragupta@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Brian R. Silver <bsilver@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/30769 Reviewed-by: Hostboot Team <hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/import/chips/p9/initfiles')
-rw-r--r--src/import/chips/p9/initfiles/p9.mca.scom.initfile12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/import/chips/p9/initfiles/p9.mca.scom.initfile b/src/import/chips/p9/initfiles/p9.mca.scom.initfile
index 47cd87692..5cbb0ec0f 100644
--- a/src/import/chips/p9/initfiles/p9.mca.scom.initfile
+++ b/src/import/chips/p9/initfiles/p9.mca.scom.initfile
@@ -114,14 +114,22 @@ define def_MEM_TYPE_2667_20_20_20 = def_MSS_FREQ_EQ_2667 && ( MCS.ATTR_E
define def_NUM_RANKS = ( MCS.ATTR_EFF_NUM_RANKS_PER_DIMM[def_PORT_INDEX][0]
+ MCS.ATTR_EFF_NUM_RANKS_PER_DIMM[def_PORT_INDEX][1] );
+
+# We don't have a div 0 problem here as we don't run this if we don't have DIMM so the number of ranks won't be 0.
define def_REFRESH_INTERVAL = ((MCS.ATTR_EFF_DRAM_TREFI[def_PORT_INDEX])/(8*def_NUM_RANKS));
+
define def_RANK_SWITCH_TCK = 4 + ((MCBIST.ATTR_MSS_FREQ-1866)/267); # 1866: 4 2133: 5 2400: 6 2667: 7
define def_BUS_TURNAROUND_TCK = 4 + ((MCBIST.ATTR_MSS_FREQ-1866)/267); # 1866: 4 2133: 5 2400: 6 2667: 7
+# Funky ... If the attribute is 0, then the value of the == operation will be 1 which bitwise-or'd with 0 gives us 1. If the attribute is != 0, then the
+# value of the == operation will be 0 which when bitwise-or'd with the attribute will give us the attribute value. Love, Prachi, Jenny, Shelton and Brian.
+define def_SLOT0_DENOMINATOR = (MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][0] == 0x0) | MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][0];
+define def_SLOT1_DENOMINATOR = (MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][1] == 0x0) | MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][1];
+
define def_SLOT0_DRAM_STACK_HEIGHT = ( MCS.ATTR_EFF_NUM_RANKS_PER_DIMM[def_PORT_INDEX][0]
- / MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][0] );
+ / def_SLOT0_DENOMINATOR );
define def_SLOT1_DRAM_STACK_HEIGHT = ( MCS.ATTR_EFF_NUM_RANKS_PER_DIMM[def_PORT_INDEX][1]
- / MCS.ATTR_EFF_NUM_MASTER_RANKS_PER_DIMM[def_PORT_INDEX][1] );
+ / def_SLOT1_DENOMINATOR );
#--******************************************************************************
#-- Dial Assignments
OpenPOWER on IntegriCloud