Skip to content

Commit

Permalink
Adding a static method to get scom failure address
Browse files Browse the repository at this point in the history
Added a static method 'SBE_SCOM_FAILURE::get_address' to
fetch scom failure address from SBE HWP ffdc data blob

Change-Id: Iec5fc6c5eb8e1ad4dbb51805b8b6d4b2d7e5ecbd
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/42275
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: PPE CI <ppe-ci+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: Santosh S. Puranik <santosh.puranik@in.ibm.com>
Reviewed-by: Sachin Gupta <sgupta2m@in.ibm.com>
Reviewed-by: Prachi Gupta <pragupta@us.ibm.com>
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/42280
Reviewed-by: Hostboot Team <hostboot@us.ibm.com>
  • Loading branch information
Shakeebbk authored and sgupta2m committed Jun 26, 2017
1 parent 828aedf commit d9c7e1f
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/import/hwpf/fapi2/tools/parseErrorInfo.pl
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
my $variable_buffer_ffdc_type = "fapi2::variable_buffer";
my $ffdc_type = "fapi2::ffdc_t";
my $mcast_type = "fapi2::mcast_t";
my $scom_addr_type = "uint64_t";
my $ffdc_count = 0;

# There are some names used in the XML files which exist in either
Expand Down Expand Up @@ -372,6 +373,14 @@ sub addFfdcMethod
$methods->{$objectNumber}{localvar} = "$ffdc_type $ffdc_uc = getFfdcData(FFDC_BUFFER[$objectNumber]);";
$methods->{$objectNumber}{assignment_string} = "l_obj.$ffdc_uc=$ffdc_uc;";
}
elsif ( $type eq $scom_addr_type )
{
if ( $arg_local_ffdc eq undef )
{
$method = "\n static $type $ffdc_uc(const sbeFfdc_t *ffdc)\n";
$method_body = " {\n return ffdc[$objectNumber].data;\n }\n\n";
}
}
else
{
$method .= " inline $class_name& set_$ffdc_uc($type $param)\n";
Expand Down Expand Up @@ -910,6 +919,9 @@ sub addFfdcMethod
$eiEntryStr .= "\tl_entries[$eiEntryCount].ffdc.iv_ffdcObjIndex = $objNum; \\\n";
$eiEntryStr .= "\tl_entries[$eiEntryCount].ffdc.iv_ffdcId = fapi2::$ffdcName; \\\n";
$eiEntryStr .= "\tl_entries[$eiEntryCount].ffdc.iv_ffdcSize = 8; \\\n";

# Add a static method to get address from ffdc blob
addFfdcMethod( \%methods, "get_address", $err->{rc}, $scom_addr_type, $eiEntryCount );
$eiEntryCount++;

# Set the FFDC ID value in a global hash. The name is <rc>_pib_error
Expand Down

0 comments on commit d9c7e1f

Please sign in to comment.