Skip to content

Commit

Permalink
Use the effective chip and group ids to calc mmio addr
Browse files Browse the repository at this point in the history
    -A testcase was executed which garded out all the MBA's
     in the system, the expectation was that hostboot would
     attempt to configure enough hardware in the system to
     successfully ipl. However instead of IPLing multiple
     checkstops and various error logs were observed.

    -The testcase to gard all the mba's and then ipl the
     system resulted in there being no useable memory available
     for the master proc (proc0). In this case there is code
     which will swap the memory map around such that the sytem
     can still IPL. One of the requirements to enable the
     ability to swap the memory map around is to use the
     effective chip and group ids for calculating the memory
     ranges.

    -When setting the inband scom address for the DMI targets
     the existing calulation is using the default fabric chip
     group ids, this commit will change the calulation to use
     the "effective" chip and group ids when calculating the
     inband scom mmio range.

Change-Id: Iaa0bed0b6ee02c02cf9319c2708f9366a97eefeb
CQ:SW422379
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/58220
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
  • Loading branch information
rjknight authored and dcrowell77 committed May 7, 2018
1 parent b9f2362 commit 83c61f3
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
7 changes: 5 additions & 2 deletions src/usr/ibscom/ibscom.C
Original file line number Diff line number Diff line change
Expand Up @@ -211,8 +211,11 @@ errlHndl_t getTargetVirtualAddress(Target* i_target,
Target* l_parentChip =
const_cast<Target *>(getParentChip(parentDMI));

uint8_t l_groupId = l_parentChip->getAttr<ATTR_FABRIC_GROUP_ID>();
uint8_t l_chipId = l_parentChip->getAttr<ATTR_FABRIC_CHIP_ID>();
// grab the effective group id
uint8_t l_groupId =
l_parentChip->getAttr<ATTR_PROC_EFF_FABRIC_GROUP_ID>();
uint8_t l_chipId =
l_parentChip->getAttr<ATTR_PROC_EFF_FABRIC_CHIP_ID>();

l_IBScomAddr = computeMemoryMapOffset( IBSCOM_BASE,
l_groupId,
Expand Down
24 changes: 12 additions & 12 deletions src/usr/intr/intrrp.C
Original file line number Diff line number Diff line change
Expand Up @@ -3437,8 +3437,8 @@ errlHndl_t IntrRp::setPsiHbBAR(intr_hdlr_t *i_proc, bool i_enable)
uint64_t l_barValue = l_baseBarValue;

TRACFCOMP(g_trac_intr,"INTR: Setting PSI BRIDGE Bar Address value for -"
" Target %p. PSI BRIDGE BAR value: 0x%016lx",
l_target,l_barValue);
" Target %.8x. PSI BRIDGE BAR value: 0x%016lx",
TARGETING::get_huid(l_target),l_barValue);

//Set base BAR Value
uint64_t size = sizeof(l_barValue);
Expand All @@ -3457,8 +3457,8 @@ errlHndl_t IntrRp::setPsiHbBAR(intr_hdlr_t *i_proc, bool i_enable)
l_barValue += PSI_BRIDGE_BAR_ENABLE;
size = sizeof(l_barValue);

TRACDCOMP(g_trac_intr,"INTR: Setting PSI BRIDGE Bar enable value for Target - %p. PSI BRIDGE BAR value: 0x%016lx",
l_target,l_barValue);
TRACFCOMP(g_trac_intr,"INTR: Setting PSI BRIDGE Bar enable value for Target - %.8x. PSI BRIDGE BAR value: 0x%016lx",
TARGETING::get_huid(l_target),l_barValue);

l_err = deviceWrite(l_target,
&l_barValue,
Expand Down Expand Up @@ -3492,9 +3492,9 @@ errlHndl_t IntrRp::setPsiHbEsbBAR(intr_hdlr_t *i_proc,
do {

uint64_t l_barValue = l_baseBarValue;
TRACFCOMP(g_trac_intr,"INTR: Target %p. "
TRACFCOMP(g_trac_intr,"INTR: Target %.8x. "
"PSI BRIDGE ESB BASE BAR value: 0x%016lx",
l_target,l_barValue);
TARGETING::get_huid(l_target),l_barValue);

uint64_t size = sizeof(l_barValue);
l_err = deviceWrite(l_target,
Expand All @@ -3512,8 +3512,8 @@ errlHndl_t IntrRp::setPsiHbEsbBAR(intr_hdlr_t *i_proc,
if (i_enable)
{
l_barValue += PSI_BRIDGE_ESB_BAR_VALID;
TRACFCOMP(g_trac_intr,"INTR: Target %p. PSI BRIDGE ESB BAR value: 0x%016lx",
l_target,l_barValue);
TRACFCOMP(g_trac_intr,"INTR: Target %.8x. PSI BRIDGE ESB BAR value: 0x%016lx",
TARGETING::get_huid(l_target),l_barValue);

size = sizeof(l_barValue);
l_err = deviceWrite(l_target,
Expand Down Expand Up @@ -3555,8 +3555,8 @@ errlHndl_t IntrRp::setXiveIvpeTmBAR1(TARGETING::Target * i_target,
l_barValue += XIVE_IVPE_TM_BAR1_VALIDATE;
}

TRACDCOMP(g_trac_intr,"INTR: Target %p. XIVE IVPE TM BAR1 value: 0x%016lx",
i_target,l_barValue);
TRACDCOMP(g_trac_intr,"INTR: Target %.8x. XIVE IVPE TM BAR1 value: 0x%016lx",
TARGETING::get_huid(i_target),l_barValue);

uint64_t size = sizeof(l_barValue);
l_err = deviceWrite(i_target,
Expand Down Expand Up @@ -3599,8 +3599,8 @@ errlHndl_t IntrRp::setXiveIcBAR(intr_hdlr_t *i_proc, bool i_enable)
l_barValue += XIVE_IC_BAR_VALID;
}

TRACDCOMP(g_trac_intr,"INTR: Target %p. XIVE IC BAR value: 0x%016lx",
l_target, l_barValue);
TRACDCOMP(g_trac_intr,"INTR: Target %.8x. XIVE IC BAR value: 0x%016lx",
TARGETING::get_huid(l_target), l_barValue);

uint64_t size = sizeof(l_barValue);
l_err = deviceWrite(l_target,
Expand Down

0 comments on commit 83c61f3

Please sign in to comment.