summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/include/usr/errl/errlmanager.H12
-rw-r--r--src/usr/cxxtest/cxxtestexec.C9
-rw-r--r--src/usr/errl/errlmanager.C17
3 files changed, 35 insertions, 3 deletions
diff --git a/src/include/usr/errl/errlmanager.H b/src/include/usr/errl/errlmanager.H
index 23319a81a..134e3958f 100644
--- a/src/include/usr/errl/errlmanager.H
+++ b/src/include/usr/errl/errlmanager.H
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -170,6 +170,14 @@ public:
return iv_hwasProcessCalloutFn;
}
+ /**
+ * @brief Determines if any non-informational logs have been committed
+ * during this boot.
+ *
+ * @return true - A non-informational log has been committed.
+ */
+ static bool errlCommittedThisBoot();
+
protected:
/**
* @brief Destructor
@@ -422,6 +430,8 @@ private:
bool iv_isSpBaseServices; // do we need to send to FSP
bool iv_isMboxEnabled; // are we able to send to FSP
std::list<msg_t *> iv_errlToSend; // msgs still to be sent to FSP
+
+ bool iv_nonInfoCommitted; //< Keeps track of any non-informational logs.
};
} // End namespace
diff --git a/src/usr/cxxtest/cxxtestexec.C b/src/usr/cxxtest/cxxtestexec.C
index 38fa2f501..5b956dc27 100644
--- a/src/usr/cxxtest/cxxtestexec.C
+++ b/src/usr/cxxtest/cxxtestexec.C
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -88,6 +88,13 @@ void cxxinit( errlHndl_t &io_taskRetErrl )
__sync_add_and_fetch(&CxxTest::g_ModulesStarted, 1);
+ // Before we launch, ensure there aren't any residual error logs from
+ // the IPL.
+ if (ERRORLOG::ErrlManager::errlCommittedThisBoot())
+ {
+ TS_FAIL("Error logs committed previously during IPL.");
+ }
+
for(std::vector<const char *>::const_iterator i = module_list.begin();
i != module_list.end(); ++i)
{
diff --git a/src/usr/errl/errlmanager.C b/src/usr/errl/errlmanager.C
index b49ddc763..edd5ac7ac 100644
--- a/src/usr/errl/errlmanager.C
+++ b/src/usr/errl/errlmanager.C
@@ -105,7 +105,8 @@ ErrlManager::ErrlManager() :
iv_maxErrlInPnor(0),
iv_pnorOpenSlot(0),
iv_isSpBaseServices(true), // queue msgs for fsp until we find we shouldnt
- iv_isMboxEnabled(false) // but mbox isn't ready yet..
+ iv_isMboxEnabled(false), // but mbox isn't ready yet..
+ iv_nonInfoCommitted(false)
{
TRACFCOMP( g_trac_errl, ENTER_MRK "ErrlManager::ErrlManager constructor" );
@@ -584,6 +585,12 @@ void ErrlManager::commitErrLog(errlHndl_t& io_err, compId_t i_committerComp )
TRACFCOMP(g_trac_errl, "commitErrLog() called by %.4X for eid=%.8x, Reasoncode=%.4X",
i_committerComp, io_err->eid(), io_err->reasonCode() );
+ if (io_err->sev() != ERRORLOG::ERRL_SEV_INFORMATIONAL)
+ {
+ iv_nonInfoCommitted = true;
+ lwsync();
+ }
+
//Ask ErrlEntry to check for any special deferred deconfigure callouts
io_err->deferredDeconfigure();
@@ -720,6 +727,14 @@ void ErrlManager::sendResourcesMsg(errlManagerNeeds i_needs)
}
return;
}
+
+bool ErrlManager::errlCommittedThisBoot()
+{
+ isync();
+ return theErrlManager::instance().iv_nonInfoCommitted;
+}
+
+
///////////////////////////////////////////////////////////////////////////////
// ErrlManager::sendErrlogToMessageQueue()
///////////////////////////////////////////////////////////////////////////////
OpenPOWER on IntegriCloud