Skip to content

Commit

Permalink
PRD: Fixed handling PM malfunction error log plugin.
Browse files Browse the repository at this point in the history
commit fixes printing of 64 bit register values in PM malfunction
error log plugin.

Change-Id: Ib4ba7351825d38cbf417020035426bf069b39813
CQ: SW454621
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70579
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: Zane C. Shelley <zshelle@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/71147
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
  • Loading branch information
premsjha authored and zane131 committed Feb 4, 2019
1 parent dbc69ab commit 5e78ec8
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/usr/diag/prdf/common/plugins/prdfProcLogParse.C
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2014,2018 */
/* Contributors Listed Below - COPYRIGHT 2014,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -87,6 +87,7 @@ enum BufLengths
{
BUF_LENGTH = 120,
LINE_LENGTH = 80,
UPPER_BYTE_POS = 10,
};

/**
Expand Down Expand Up @@ -349,6 +350,8 @@ uint32_t parseRegFfdc( ErrlUsrParser& i_parser, uint8_t* i_buf, uint32_t i_lengt
{
FfdcSummSubSectHdr* l_pSubSecHdr = (FfdcSummSubSectHdr*)i_buf;
uint64_t* l_secBufPtr = (uint64_t*)( i_buf + sizeof( FfdcSummSubSectHdr ) );
uint32_t l_tempWord = 0;
uint64_t l_tempDbWord = 0;

if( 0 == i_length )
{
Expand Down Expand Up @@ -407,14 +410,18 @@ uint32_t parseRegFfdc( ErrlUsrParser& i_parser, uint8_t* i_buf, uint32_t i_lengt
memset( l_lineStr, 0x00, BUF_LENGTH );
memset( l_hdrStr, 0x00, BUF_LENGTH );
snprintf( l_hdrStr, BUF_LENGTH, "%s", (*itRegList).c_str() );
l_tempDbWord = htobe64(*l_secBufPtr);

if( INVALID_DATA == htobe64(*l_secBufPtr) )
if( INVALID_DATA == l_tempDbWord )
{
memcpy( l_lineStr, "--", BUF_LENGTH );
}
else
{
snprintf( l_lineStr, BUF_LENGTH, "0x%016lx", htobe64(*l_secBufPtr) );
l_tempWord = (l_tempDbWord >> 32);
snprintf( l_lineStr, BUF_LENGTH, "0x%08x", l_tempWord );
l_tempWord = (uint32_t)l_tempDbWord;
snprintf( l_lineStr + UPPER_BYTE_POS, (BUF_LENGTH - UPPER_BYTE_POS), "%08x", l_tempWord );
}

i_parser.PrintString( l_hdrStr, l_lineStr );
Expand Down

0 comments on commit 5e78ec8

Please sign in to comment.