diff options
| author | Corey Swenson <cswenson@us.ibm.com> | 2017-04-25 09:47:34 -0500 |
|---|---|---|
| committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2017-04-28 14:14:12 -0400 |
| commit | 2a1c0da1e1766caab280528cfa4c74433718c081 (patch) | |
| tree | 1ee0b5a137d9a53e8d75678ebfc316d92467b913 /src/usr/targeting/common | |
| parent | 38bb2df0d99cbd6235f43ef44ebbe205e6b5f900 (diff) | |
| download | blackbird-hostboot-2a1c0da1e1766caab280528cfa4c74433718c081.tar.gz blackbird-hostboot-2a1c0da1e1766caab280528cfa4c74433718c081.zip | |
Handle SMT4/SMT8 fuse bits
Change-Id: I8fc108877714ff76103510b7801af72a94e5aae3
RTC:160720
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/39778
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Martin Gloff <mgloff@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/targeting/common')
| -rw-r--r-- | src/usr/targeting/common/util.C | 57 |
1 files changed, 44 insertions, 13 deletions
diff --git a/src/usr/targeting/common/util.C b/src/usr/targeting/common/util.C index 80e4147b8..92fec0365 100644 --- a/src/usr/targeting/common/util.C +++ b/src/usr/targeting/common/util.C @@ -306,32 +306,63 @@ uint8_t is_fused_mode( ) TARGETING::Target * sys = NULL; TARGETING::targetService().getTopLevelTarget( sys ); assert(sys != NULL); - TARGETING::PAYLOAD_KIND l_payload = sys->getAttr<ATTR_PAYLOAD_KIND>(); - uint8_t l_attrValue = sys->getAttr<ATTR_FUSED_CORE_OPTION>(); + /* + Fused Mode - if (FUSED_CORE_OPTION_USING_DEFAULT_CORES == l_attrValue) + ATTR_FUSED_CORE_MODE / ATTR_FUSED_CORE_OPTION / ATTR_PAYLOAD_KIND + + smt4_default / default_cores / phyp --> fused + smt4_default / default_cores / opal --> notfused + smt4_default / normal_cores / * --> notfused + smt4_default / fused_cores / * --> fused + + smt4_only / default_cores / * --> notfused + smt4_only / normal_cores / * --> notfused + smt4_only / fused_cores / * --> fused + + smt8_only / default_cores / * --> fused + smt8_only / normal_cores / * --> notfused + smt8_only / fused_cores / * --> fused + */ + + uint8_t l_mode = sys->getAttr<ATTR_FUSED_CORE_MODE>();; + uint8_t l_option = sys->getAttr<ATTR_FUSED_CORE_OPTION>();; + PAYLOAD_KIND l_payload = sys->getAttr<ATTR_PAYLOAD_KIND>(); + + if (FUSED_CORE_OPTION_USING_DEFAULT_CORES == l_option) { - // if payload is PHYP, use FUSED mode - // Anything else, use NORMAL mode - if (PAYLOAD_KIND_PHYP == l_payload) + if (FUSED_CORE_MODE_SMT4_DEFAULT == l_mode) { - l_fused = true; + if (PAYLOAD_KIND_PHYP == l_payload) + { + l_fused = true; + } + else + { + l_fused = false; + } } - else + else if (FUSED_CORE_MODE_SMT4_ONLY == l_mode) { l_fused = false; } + else // SMT8_ONLY + { + l_fused = true; + } } - else + else if (FUSED_CORE_OPTION_USING_NORMAL_CORES == l_option) { - l_fused = (l_attrValue == FUSED_CORE_OPTION_USING_NORMAL_CORES) ? - false : true; + l_fused = false; + } + else // USING_FUSED_CORES + { + l_fused = true; } - return(l_fused); } // end is_fused_mode -} +} // end namespace TARGETING |

