summaryrefslogtreecommitdiffstats
path: root/src/usr
diff options
context:
space:
mode:
authorBill Schwartz <whs@us.ibm.com>2014-05-19 21:44:46 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-06-30 19:31:30 -0500
commit3b65dfb45938d0e864749fe97f044c275f56f3db (patch)
tree2de41582ee15f85276a0e83002e1ae5bba622bad /src/usr
parent682fbef52aa03bf5920ecc422b9bdb4546f31143 (diff)
downloadtalos-hostboot-3b65dfb45938d0e864749fe97f044c275f56f3db.tar.gz
talos-hostboot-3b65dfb45938d0e864749fe97f044c275f56f3db.zip
Merge HWAS commits from Stradale
These changes are to reduce the amount of trace entries, disable garding, and to print the model type. Change-Id: Iff1cd4995367c7bfad621f41a36e0080007ec6ef RTC: 97496 Origin: Google Shared Technology Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/11172 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr')
-rw-r--r--src/usr/hwas/HBconfig10
-rw-r--r--src/usr/hwas/common/hwas.C10
-rw-r--r--src/usr/hwas/hwasPlatDeconfigGard.C12
-rw-r--r--src/usr/mbox/HBconfig4
-rw-r--r--src/usr/mbox/mailboxsp.C14
-rw-r--r--src/usr/targeting/HBconfig6
-rw-r--r--src/usr/targeting/common/test/testcommontargeting.H21
-rw-r--r--src/usr/targeting/targetservicestart.C17
8 files changed, 80 insertions, 14 deletions
diff --git a/src/usr/hwas/HBconfig b/src/usr/hwas/HBconfig
new file mode 100644
index 000000000..d41516809
--- /dev/null
+++ b/src/usr/hwas/HBconfig
@@ -0,0 +1,10 @@
+config SKIP_RESTRICT_EX_UNITS
+ default n
+ help
+ Skip restricting the number of ex/cores based on PR keyword
+
+config NO_GARD_SUPPORT
+ default n
+ help
+ Skip guarding when set
+
diff --git a/src/usr/hwas/common/hwas.C b/src/usr/hwas/common/hwas.C
index 73843b505..2b6730e09 100644
--- a/src/usr/hwas/common/hwas.C
+++ b/src/usr/hwas/common/hwas.C
@@ -5,7 +5,10 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2014 */
+/* Contributors Listed Below - COPYRIGHT 2012,2014 */
+/* [+] Google Inc. */
+/* [+] International Business Machines Corp. */
+/* */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); */
/* you may not use this file except in compliance with the License. */
@@ -34,6 +37,9 @@
/******************************************************************************/
#include <stdint.h>
#include <algorithm>
+#ifdef __HOSTBOOT_MODULE
+#include <config.h>
+#endif
#include <targeting/common/commontargeting.H>
#include <targeting/common/utilFilter.H>
@@ -465,6 +471,7 @@ errlHndl_t discoverTargets()
// call to restrict EX units, marking bad units as present=false;
// deconfigReason = 0 because present is false so this is not a
// deconfigured event.
+#ifndef CONFIG_SKIP_RESTRICT_EX_UNITS
errl = restrictEXunits(l_procPRList, false, 0);
if (errl)
@@ -472,6 +479,7 @@ errlHndl_t discoverTargets()
HWAS_ERR("discoverTargets: restrictEXunits failed");
break;
}
+#endif
// call invokePresentByAssoc() to obtain functional MCS's, MEMBUFs, and
// DIMM's, call algorithm function presentByAssoc() to determine
diff --git a/src/usr/hwas/hwasPlatDeconfigGard.C b/src/usr/hwas/hwasPlatDeconfigGard.C
index 425fea23a..261ad13de 100644
--- a/src/usr/hwas/hwasPlatDeconfigGard.C
+++ b/src/usr/hwas/hwasPlatDeconfigGard.C
@@ -5,7 +5,10 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* COPYRIGHT International Business Machines Corp. 2013,2014 */
+/* Contributors Listed Below - COPYRIGHT 2013,2014 */
+/* [+] Google Inc. */
+/* [+] International Business Machines Corp. */
+/* */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); */
/* you may not use this file except in compliance with the License. */
@@ -38,6 +41,7 @@
#include <vpd/mvpdenums.H>
#include <stdio.h>
#include <sys/mm.h>
+#include <config.h>
#include <pnor/pnorif.H>
@@ -67,6 +71,7 @@ errlHndl_t DeconfigGard::platClearGardRecords(
{
errlHndl_t l_pErr = NULL;
+#ifndef CONFIG_NO_GARD_SUPPORT
EntityPath l_targetId;
if (!i_pTarget)
{
@@ -118,6 +123,7 @@ errlHndl_t DeconfigGard::platClearGardRecords(
}
HWAS_MUTEX_UNLOCK(iv_mutex);
+#endif // CONFIG_NO_GARD_SUPPORT
return l_pErr;
}
@@ -128,6 +134,7 @@ errlHndl_t DeconfigGard::platGetGardRecords(
errlHndl_t l_pErr = NULL;
o_records.clear();
+#ifndef CONFIG_NO_GARD_SUPPORT
EntityPath l_targetId;
if (!i_pTarget)
{
@@ -173,6 +180,7 @@ errlHndl_t DeconfigGard::platGetGardRecords(
HWAS_MUTEX_UNLOCK(iv_mutex);
HWAS_INF("Get returning %d GARD Records", o_records.size());
+#endif // CONFIG_NO_GARD_SUPPORT
return l_pErr;
}
@@ -186,6 +194,7 @@ errlHndl_t DeconfigGard::platCreateGardRecord(
get_huid(i_pTarget), i_errlEid);
errlHndl_t l_pErr = NULL;
+#ifndef CONFIG_NO_GARD_SUPPORT
HWAS_MUTEX_LOCK(iv_mutex);
do
@@ -350,6 +359,7 @@ errlHndl_t DeconfigGard::platCreateGardRecord(
while (0);
HWAS_MUTEX_UNLOCK(iv_mutex);
+#endif // CONFIG_NO_GARD_SUPPORT
return l_pErr;
}
diff --git a/src/usr/mbox/HBconfig b/src/usr/mbox/HBconfig
new file mode 100644
index 000000000..02ca03467
--- /dev/null
+++ b/src/usr/mbox/HBconfig
@@ -0,0 +1,4 @@
+config DROPPED_MSG_WARNING_AS_DEBUG
+ default n
+ help
+ Debug trace for dropped messages due to mailbox being disabled
diff --git a/src/usr/mbox/mailboxsp.C b/src/usr/mbox/mailboxsp.C
index 997209682..90d5ab8c5 100644
--- a/src/usr/mbox/mailboxsp.C
+++ b/src/usr/mbox/mailboxsp.C
@@ -5,7 +5,10 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* COPYRIGHT International Business Machines Corp. 2012,2014 */
+/* Contributors Listed Below - COPYRIGHT 2012,2014 */
+/* [+] Google Inc. */
+/* [+] International Business Machines Corp. */
+/* */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); */
/* you may not use this file except in compliance with the License. */
@@ -28,6 +31,7 @@
#include "mailboxsp.H"
#include "mboxdd.H"
#include "ipcSp.H"
+#include <config.h>
#include <sys/task.h>
#include <initservice/taskargs.H>
#include <initservice/initserviceif.H>
@@ -477,11 +481,19 @@ void MailboxSp::handleNewMessage(msg_t * i_msg)
if(iv_disabled)
{
+#ifdef CONFIG_DROPPED_MSG_WARNING_AS_DEBUG
+ TRACDCOMP(g_trac_mbox,WARN_MRK
+ "MSGSEND - mailboxsp is disabled. Message dropped!"
+ " msgQ=0x%x type=0x%x",
+ mbox_msg.msg_queue_id,
+ mbox_msg.msg_payload.type);
+#else
TRACFCOMP(g_trac_mbox,WARN_MRK
"MSGSEND - mailboxsp is disabled. Message dropped!"
" msgQ=0x%x type=0x%x",
mbox_msg.msg_queue_id,
mbox_msg.msg_payload.type);
+#endif
if(!i_msg_is_async) // synchronous
{
diff --git a/src/usr/targeting/HBconfig b/src/usr/targeting/HBconfig
new file mode 100644
index 000000000..85f8d22da
--- /dev/null
+++ b/src/usr/targeting/HBconfig
@@ -0,0 +1,6 @@
+config TARG_TRACE_AS_DEBUG
+ default n
+ help
+ Reduce number of traces by making TARG_ENTER and TARG_EXIT debug traces
+
+# @TODO RTC:106879 BMC:Console - May reconsider approach to quiet trace.
diff --git a/src/usr/targeting/common/test/testcommontargeting.H b/src/usr/targeting/common/test/testcommontargeting.H
index b25853c62..c38e8157e 100644
--- a/src/usr/targeting/common/test/testcommontargeting.H
+++ b/src/usr/targeting/common/test/testcommontargeting.H
@@ -5,7 +5,10 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2014 */
+/* Contributors Listed Below - COPYRIGHT 2012,2014 */
+/* [+] Google Inc. */
+/* [+] International Business Machines Corp. */
+/* */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); */
/* you may not use this file except in compliance with the License. */
@@ -1222,7 +1225,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
{
}
- TARG_TS_TRACE(INF_MRK "Found %d total targets", l_count);
+ TARG_TS_TRACE(INFO_MRK "Found %d total targets", l_count);
PredicateCTM l_procs(CLASS_CHIP);
PredicateCTM l_enclosures(CLASS_ENC);
@@ -1239,7 +1242,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
l_path.dump();
}
- TARG_TS_TRACE(INF_MRK "Found %d targets that are chips or enclosures ",
+ TARG_TS_TRACE(INFO_MRK "Found %d targets that are chips or enclosures ",
l_count);
l_query.Not();
@@ -1250,7 +1253,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
{
}
- TARG_TS_TRACE(INF_MRK "Found %d targets that are not chips or "
+ TARG_TS_TRACE(INFO_MRK "Found %d targets that are not chips or "
"enclosures",l_count);
Target* l_pMasterProcChipTargetHandle = NULL;
@@ -1281,7 +1284,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
l_path.dump();
}
- TARG_TS_TRACE(INF_MRK "Found %d targets that are ex/mba units off "
+ TARG_TS_TRACE(INFO_MRK "Found %d targets that are ex/mba units off "
"master processor",l_count);
TARG_TS_TRACE(EXIT_MRK "testComplexFilter" );
@@ -1292,7 +1295,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
TARG_TS_TRACE(ENTER_MRK "testFapiToHbMacros" );
- TARG_TS_TRACE(INF_MRK "Now using direct access macros");
+ TARG_TS_TRACE(INFO_MRK "Now using direct access macros");
using namespace TARGETING;
using namespace fapi;
@@ -1339,7 +1342,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
"attribute access",l_xscom,0x0003FC00000000ULL);
}
- TARG_TS_TRACE(INF_MRK "Now using FAPI get macros");
+ TARG_TS_TRACE(INFO_MRK "Now using FAPI get macros");
memset(l_dummyRw,0x00,sizeof(l_dummyRw));
fapi::ReturnCode l_rc = FAPI_ATTR_GET(
@@ -1355,7 +1358,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
l_dummyRw[0][2][4]);
}
- TARG_TS_TRACE(INF_MRK "Now using FAPI set macros");
+ TARG_TS_TRACE(INFO_MRK "Now using FAPI set macros");
l_dummyRw[0][2][3] = 6;
l_rc = FAPI_ATTR_SET(ATTR_DUMMY_SCRATCH_PLAT_INIT_UINT8, NULL,
@@ -1379,7 +1382,7 @@ class CommonTargetingTestSuite: public CxxTest::TestSuite
"prior write",l_dummyRw[0][2][3]);
}
- TARG_TS_TRACE(INF_MRK "Now using targets without the attribute");
+ TARG_TS_TRACE(INFO_MRK "Now using targets without the attribute");
memset(l_dummyRw,0x00,sizeof(l_dummyRw));
EntityPath l_realPath(EntityPath::PATH_PHYSICAL);
diff --git a/src/usr/targeting/targetservicestart.C b/src/usr/targeting/targetservicestart.C
index 26679bf7d..8677c61ce 100644
--- a/src/usr/targeting/targetservicestart.C
+++ b/src/usr/targeting/targetservicestart.C
@@ -5,7 +5,10 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* COPYRIGHT International Business Machines Corp. 2012,2014 */
+/* Contributors Listed Below - COPYRIGHT 2012,2014 */
+/* [+] Google Inc. */
+/* [+] International Business Machines Corp. */
+/* */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); */
/* you may not use this file except in compliance with the License. */
@@ -104,6 +107,16 @@ static void initTargeting(errlHndl_t& io_pError)
initializeAttributes(l_targetService);
checkProcessorTargeting(l_targetService);
+ // Print out top-level model value from loaded targeting values.
+ // @TODO RTC:88056 Make the model printed more meaniful
+ Target* l_pTopLevel = NULL;
+ l_targetService.getTopLevelTarget(l_pTopLevel);
+ ATTR_MODEL_type l_model = MODEL_NA;
+ if (l_pTopLevel->tryGetAttr<ATTR_MODEL>(l_model)) {
+ TARG_INF("Initialized targeting for model: %s",
+ l_pTopLevel->getAttrAsString<ATTR_MODEL>());
+ }
+
// call ErrlManager function - tell him that TARG is ready!
ERRORLOG::ErrlManager::errlResourceReady(ERRORLOG::TARG);
}
@@ -114,7 +127,7 @@ static void initTargeting(errlHndl_t& io_pError)
}
/**
- * @brief Create _start entry point using task entry macro and vector to
+ * @brief Create _start entry point using task entry macro and vector to
* initTargeting function
*/
TASK_ENTRY_MACRO(initTargeting);
OpenPOWER on IntegriCloud