Removed ChipType_t dependency in HardwareRegister

This dependency defeated the purpose of the flyweights because a
register that does not differ between chip model/EC would end up having
an instance for each model/EC. The explodes the memory used for these
objects.

This does expose a problem where someone may try to access a register
that does not exist for a specific chip type. However, they should be
getting the register objects from the IsolationChip class for the
specific chip type anyway. Therefore, the exposure is minimal compared
to the memory savings.

Change-Id: I926a71ea180fca7e39572ffe17d9f64e35395e53
Signed-off-by: Zane Shelley <zshelle@us.ibm.com>
diff --git a/src/register/hei_hardware_register.cpp b/src/register/hei_hardware_register.cpp
index bf9a55a..2d2167e 100644
--- a/src/register/hei_hardware_register.cpp
+++ b/src/register/hei_hardware_register.cpp
@@ -14,9 +14,6 @@
 
 const BitString* HardwareRegister::getBitString(const Chip& i_chip) const
 {
-    // Verify this register belongs on i_chip.
-    verifyAccessorChip(i_chip);
-
     // Calling read() will ensure that an entry exists in the cache and the
     // entry has at been synched with hardware at least once. Note that we
     // cannot read hardware for write-only registers. In this case, an entry
@@ -35,9 +32,6 @@
 
 BitString& HardwareRegister::accessBitString(const Chip& i_chip)
 {
-    // Verify this register belongs on i_chip.
-    verifyAccessorChip(i_chip);
-
     // Calling read() will ensure that an entry exists in the cache and the
     // entry has at been synched with hardware at least once. Note that we
     // cannot read hardware for write-only registers. In this case, an entry
@@ -58,9 +52,6 @@
 {
     bool accessFailure = false;
 
-    // Verify this register belongs on i_chip.
-    verifyAccessorChip(i_chip);
-
     // Read from hardware only if the read is forced or the entry for this
     // instance does not exist in the cache.
     if (i_force || !queryCache(i_chip))
@@ -76,7 +67,7 @@
 
         // Read this register from hardware.
         accessFailure = registerRead(i_chip, bs.getBufAddr(), sz_buffer,
-                                     getRegisterType(), getAddress());
+                                     getType(), getAddress());
         if (accessFailure)
         {
             // The read failed and we can't trust what was put in the register
@@ -102,9 +93,6 @@
 {
     bool accessFailure = false;
 
-    // Verify this register belongs on i_chip.
-    verifyAccessorChip(i_chip);
-
     // This register must be writable.
     HEI_ASSERT(queryAttrFlag(REG_ATTR_ACCESS_WRITE));
 
@@ -118,8 +106,8 @@
     size_t sz_buffer = BitString::getMinBytes(bs.getBitLen());
 
     // Write to this register to hardware.
-    accessFailure = registerWrite(i_chip, bs.getBufAddr(), sz_buffer,
-                                  getRegisterType(), getAddress());
+    accessFailure = registerWrite(i_chip, bs.getBufAddr(), sz_buffer, getType(),
+                                  getAddress());
 
     if (accessFailure)
     {