summaryrefslogtreecommitdiffstats
path: root/src/usr/pnor
diff options
context:
space:
mode:
authorDan Crowell <dcrowell@us.ibm.com>2014-01-07 09:30:51 -0600
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-01-10 16:19:14 -0600
commitaa83ebd12d6cf6d6ead06e45ab61d46a53a15be3 (patch)
treed6a587a8582ac9d085b08e028c757a0ea94bb825 /src/usr/pnor
parentea2a49ff0cd3827458025f75d5b6bd7054d18779 (diff)
downloadblackbird-hostboot-aa83ebd12d6cf6d6ead06e45ab61d46a53a15be3.tar.gz
blackbird-hostboot-aa83ebd12d6cf6d6ead06e45ab61d46a53a15be3.zip
Remove leftover fixme/todo and update error callouts
Remove all untagged fixme/todo comments Adde new parm to error log constructor to avoid extra code in common software error case Update error callouts Add strncpy Change-Id: I8bd8f48193a96b79db91ed35c4fd485e6da38dba RTC: 67921 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/7921 Tested-by: Jenkins Server Reviewed-by: Michael Baiocchi <baiocchi@us.ibm.com> Reviewed-by: Brian H. Horton <brianh@linux.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/pnor')
-rw-r--r--src/usr/pnor/pnordd.C20
-rw-r--r--src/usr/pnor/pnordd.H8
-rw-r--r--src/usr/pnor/pnorrp.C50
-rw-r--r--src/usr/pnor/test/pnorrptest.H6
4 files changed, 49 insertions, 35 deletions
diff --git a/src/usr/pnor/pnordd.C b/src/usr/pnor/pnordd.C
index e8bd3d738..4d67da3e0 100644
--- a/src/usr/pnor/pnordd.C
+++ b/src/usr/pnor/pnordd.C
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -722,7 +722,7 @@ errlHndl_t PnorDD::pollSfcOpComplete(uint64_t i_pollTime)
if( l_err ) { break; }
// check for errors or timeout
- // TODO: What errors do we check?
+ // TODO: RTC:62718 What errors do we check?
if( (sfc_stat.done == 0) )
{
TRACFCOMP(g_trac_pnor,
@@ -746,8 +746,8 @@ errlHndl_t PnorDD::pollSfcOpComplete(uint64_t i_pollTime)
poll_time),
TWO_UINT32_TO_UINT64(sfc_stat.data32,0));
- l_err->collectTrace("PNOR");
- l_err->collectTrace("XSCOM");
+ l_err->collectTrace(PNOR_COMP_NAME);
+ l_err->collectTrace(XSCOM_COMP_NAME);
//@todo (RTC:37744) - Any cleanup or recovery needed?
break;
}
@@ -849,8 +849,8 @@ errlHndl_t PnorDD::micronFlagStatus(uint64_t i_pollTime)
poll_time),
TWO_UINT32_TO_UINT64(opStatus,0));
- l_err->collectTrace("PNOR");
- l_err->collectTrace("XSCOM");
+ l_err->collectTrace(PNOR_COMP_NAME);
+ l_err->collectTrace(XSCOM_COMP_NAME);
//Erase & Program error bits are sticky, so they need to be cleared.
@@ -1366,8 +1366,8 @@ errlHndl_t PnorDD::readLPC(uint32_t i_addr,
PNOR::RC_LPC_ERROR,
TWO_UINT32_TO_UINT64(i_addr,poll_time),
eccb_stat.data64);
- l_err->collectTrace("PNOR");
- l_err->collectTrace("XSCOM");
+ l_err->collectTrace(PNOR_COMP_NAME);
+ l_err->collectTrace(XSCOM_COMP_NAME);
//@todo (RTC:37744) - Any cleanup or recovery needed?
break;
}
@@ -1475,8 +1475,8 @@ errlHndl_t PnorDD::writeLPC(uint32_t i_addr,
PNOR::RC_LPC_ERROR,
TWO_UINT32_TO_UINT64(0,i_addr),
eccb_stat.data64);
- l_err->collectTrace("PNOR");
- l_err->collectTrace("XSCOM");
+ l_err->collectTrace(PNOR_COMP_NAME);
+ l_err->collectTrace(XSCOM_COMP_NAME);
//@todo (RTC:37744) - Any cleanup or recovery needed?
break;
}
diff --git a/src/usr/pnor/pnordd.H b/src/usr/pnor/pnordd.H
index 7f13e43c5..441eac3ca 100644
--- a/src/usr/pnor/pnordd.H
+++ b/src/usr/pnor/pnordd.H
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -205,9 +205,11 @@ class PnorDD
enum {
- SFC_CMDBUF_SIZE = 256, /**< SFC Command buffer is 0x100/256 bytes/0x40 words */
+ SFC_CMDBUF_SIZE = 256, /**< SFC Command buffer is
+ 0x100/256 bytes/0x40 words */
- SFC_POLL_TIME_NS = 400000, /**< todo: Find out Max time to wait */
+ SFC_POLL_TIME_NS = 400000, /**< todo: RTC:62718 Find out
+ Max time to wait */
SFC_POLL_INCR_NS = 10, /**< minimum increment during poll */
};
diff --git a/src/usr/pnor/pnorrp.C b/src/usr/pnor/pnorrp.C
index 1d52b2a39..9ae43e136 100644
--- a/src/usr/pnor/pnorrp.C
+++ b/src/usr/pnor/pnorrp.C
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -232,11 +232,13 @@ void PnorRP::initDaemon()
* @userdata2 rc from mm_alloc_block
* @devdesc PnorRP::initDaemon> Error from mm_alloc_block
*/
- l_errhdl = new ERRORLOG::ErrlEntry(ERRORLOG::ERRL_SEV_UNRECOVERABLE,
- PNOR::MOD_PNORRP_INITDAEMON,
- PNOR::RC_EXTERNAL_ERROR,
- TO_UINT64(BASE_VADDR),
- TO_UINT64(rc));
+ l_errhdl = new ERRORLOG::ErrlEntry(
+ ERRORLOG::ERRL_SEV_UNRECOVERABLE,
+ PNOR::MOD_PNORRP_INITDAEMON,
+ PNOR::RC_EXTERNAL_ERROR,
+ TO_UINT64(BASE_VADDR),
+ TO_UINT64(rc),
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
break;
}
@@ -298,7 +300,8 @@ errlHndl_t PnorRP::getSectionInfo( PNOR::SectionId i_section,
PNOR::MOD_PNORRP_GETSECTIONINFO,
PNOR::RC_STARTUP_FAIL,
TO_UINT64(i_section),
- rc);
+ rc,
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
// set the return section to our invalid data
@@ -323,7 +326,8 @@ errlHndl_t PnorRP::getSectionInfo( PNOR::SectionId i_section,
PNOR::MOD_PNORRP_GETSECTIONINFO,
PNOR::RC_INVALID_SECTION,
TO_UINT64(i_section),
- iv_TOC_used);
+ iv_TOC_used,
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
// set the return section to our invalid data
@@ -681,13 +685,16 @@ void PnorRP::waitForMessage()
* @reasoncode PNOR::RC_INVALID_MESSAGE_TYPE
* @userdata1 Message type
* @userdata2 Requested Virtual Address
- * @devdesc PnorRP::waitForMessage> Unrecognized message type
+ * @devdesc PnorRP::waitForMessage> Unrecognized
+ * message type
*/
- l_errhdl = new ERRORLOG::ErrlEntry(ERRORLOG::ERRL_SEV_UNRECOVERABLE,
- PNOR::MOD_PNORRP_WAITFORMESSAGE,
- PNOR::RC_INVALID_MESSAGE_TYPE,
- TO_UINT64(message->type),
- (uint64_t)eff_addr);
+ l_errhdl = new ERRORLOG::ErrlEntry(
+ ERRORLOG::ERRL_SEV_UNRECOVERABLE,
+ PNOR::MOD_PNORRP_WAITFORMESSAGE,
+ PNOR::RC_INVALID_MESSAGE_TYPE,
+ TO_UINT64(message->type),
+ (uint64_t)eff_addr,
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
status_rc = -EINVAL; /* Invalid argument */
}
@@ -704,11 +711,13 @@ void PnorRP::waitForMessage()
* @userdata2 Requested Virtual Address
* @devdesc PnorRP::waitForMessage> Unrecognized message type
*/
- l_errhdl = new ERRORLOG::ErrlEntry(ERRORLOG::ERRL_SEV_UNRECOVERABLE,
- PNOR::MOD_PNORRP_WAITFORMESSAGE,
- PNOR::RC_INVALID_ASYNC_MESSAGE,
- TO_UINT64(message->type),
- (uint64_t)eff_addr);
+ l_errhdl = new ERRORLOG::ErrlEntry(
+ ERRORLOG::ERRL_SEV_UNRECOVERABLE,
+ PNOR::MOD_PNORRP_WAITFORMESSAGE,
+ PNOR::RC_INVALID_ASYNC_MESSAGE,
+ TO_UINT64(message->type),
+ (uint64_t)eff_addr,
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
status_rc = -EINVAL; /* Invalid argument */
}
@@ -924,7 +933,8 @@ errlHndl_t PnorRP::computeDeviceAddr( void* i_vaddr,
PNOR::MOD_PNORRP_COMPUTEDEVICEADDR,
PNOR::RC_INVALID_ADDRESS,
l_vaddr,
- BASE_VADDR);
+ BASE_VADDR,
+ true /*Add HB SW Callout*/);
l_errhdl->collectTrace(PNOR_COMP_NAME);
return l_errhdl;
}
diff --git a/src/usr/pnor/test/pnorrptest.H b/src/usr/pnor/test/pnorrptest.H
index d96379a8c..0ad5fc348 100644
--- a/src/usr/pnor/test/pnorrptest.H
+++ b/src/usr/pnor/test/pnorrptest.H
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -431,7 +431,9 @@ class PnorRpTest : public CxxTest::TestSuite
*/
void test_AddrReadWrite(void)
{
- return; //@todo - enable this after Task 3445
+ // Leaving disabled because a regular boot tests all of this anyway,
+ // but want to leave this here for possible future unit testing.
+ return;
TRACFCOMP( g_trac_pnor, "PnorRpTest::test_AddrReadWrite> Start" );
uint64_t fails = 0;
uint64_t total = 0;
OpenPOWER on IntegriCloud