Skip to content

Commit

Permalink
Risk level 3/4/5 support: Step 2 - image update to TOR v7
Browse files Browse the repository at this point in the history
- This commit updates the image ring sections to TOR v7.
- It will fail with EKB FSP CI until we include the prereq to the
  merged step 1 commit in PPE and HB.

Key_Cronus_Test=XIP_REGRESS

cmvc-prereq: 1053262
cmvc-prereq: 1053182
Change-Id: Ie7452fe42877297da4f0da5cd4e51c989b6ac28d
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/57421
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: HWSV CI <hwsv-ci+hostboot@us.ibm.com>
Tested-by: PPE CI <ppe-ci+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Tested-by: Cronus HW CI <cronushw-ci+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: James N. Klazynski <jklazyns@us.ibm.com>
Reviewed-by: Joseph J. McGill <jmcgill@us.ibm.com>
Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com>
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/57432
Reviewed-by: Sachin Gupta <sgupta2m@in.ibm.com>
  • Loading branch information
cmolsen authored and sgupta2m committed May 3, 2018
1 parent a7e21bc commit 3433298
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/hwpf/plat_ring_traverse.C
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ fapi2::ReturnCode getRS4ImageFromTor(
uint8_t l_torVersion = ((TorHeader_t*)i_sectionTOR)->version;
SectionTOR* l_sectionTOR = (SectionTOR*)((uint8_t*)i_sectionTOR + l_torHdrSz);
uint8_t l_numVarAdjust = 0;

// Determine the Offset ID and Ring Type for the given Ring ID.
uint32_t l_torOffset = 0;
RingType_t l_ringType = COMMON_RING;
Expand All @@ -144,6 +144,14 @@ fapi2::ReturnCode getRS4ImageFromTor(
do
{

if (l_torVersion > TOR_VERSION)
{
SBE_TRACE("Image TOR version (=%d) > code TOR version (=%d) not allowed",
l_torVersion, TOR_VERSION);
l_rc = fapi2::FAPI2_RC_INVALID_PARAMETER;
break;
}

if((i_ringID >= NUM_RING_IDS))
{
SBE_TRACE("Invalid Ring ID - %d", i_ringID);
Expand Down
1 change: 1 addition & 0 deletions src/import/chips/p9/utils/imageProcs/p9_tor.C
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,7 @@ int tor_access_ring( void* i_ringSection, // Ring section ptr
}

if ( torMagic >> 8 != TOR_MAGIC ||
torHeader->version > TOR_VERSION || // Code cannot be forward compatible to a newer image
torHeader->version == 0 ||
torHeader->chipType >= NUM_CHIP_TYPES )
{
Expand Down

0 comments on commit 3433298

Please sign in to comment.