Initial support to parse a Chip Data File
Change-Id: Ib5a7d8344922f8288c23f5bedd304e282dcfaada
Signed-off-by: Zane Shelley <zshelle@us.ibm.com>
diff --git a/src/isolator/hei_isolator.cpp b/src/isolator/hei_isolator.cpp
index dc4d09b..db5668e 100644
--- a/src/isolator/hei_isolator.cpp
+++ b/src/isolator/hei_isolator.cpp
@@ -2,14 +2,9 @@
#include <hei_includes.hpp>
#include <isolator/hei_isolation_node.hpp>
#include <isolator/hei_isolator.hpp>
-#include <register/hei_hardware_register.hpp>
-#include <util/hei_flyweight.hpp>
-
-// BEGIN temporary code
-#include <isolator/hei_isolation_node.hpp>
#include <register/hei_operator_register.hpp>
#include <register/hei_scom_register.hpp>
-// END temporary code
+#include <util/hei_flyweight.hpp>
namespace libhei
{
@@ -35,13 +30,11 @@
//------------------------------------------------------------------------------
-void Isolator::initialize(void* i_buffer, size_t i_bufferSize)
-{
- // TODO
-}
-
void Isolator::uninitialize()
{
+ // Clear all of the IsolationChip objects.
+ iv_isoChips.clear();
+
// Remove all of the IsolationNode objects stored in the flyweights. This
// must be done before removing the HardwareRegister objects
Flyweight<IsolationNode>::getSingleton().clear();
@@ -67,8 +60,12 @@
// Analyze active error on each chip.
for (const auto& chip : i_chipList)
{
- // TODO
- HEI_INF("Isolator::isolate(%p,%u)", chip.getChip(), chip.getType());
+ // Isolation objects for this chip's type must exist.
+ const auto& itr = iv_isoChips.find(chip.getType());
+ HEI_ASSERT(iv_isoChips.end() != itr);
+
+ // Analyze this chip.
+ itr->second->analyze(chip, o_isoData);
}
}