summaryrefslogtreecommitdiffstats
path: root/src/usr/ipmi
diff options
context:
space:
mode:
authorRichard J. Knight <rjknight@us.ibm.com>2016-02-03 10:36:52 -0600
committerDaniel M. Crowell <dcrowell@us.ibm.com>2016-02-24 16:12:06 -0600
commitbab51274cbfb901e2c6d1f2e76513eb4c728f9f5 (patch)
treed59b0312cfc68b6cf57cfb55e8f2014972729ed5 /src/usr/ipmi
parent11f529cc8f008ffcb21101b35c002310f1f77ab7 (diff)
downloadtalos-hostboot-bab51274cbfb901e2c6d1f2e76513eb4c728f9f5.tar.gz
talos-hostboot-bab51274cbfb901e2c6d1f2e76513eb4c728f9f5.zip
DIMM Present sensor not active after dimm is deconfigured
-Modified set sensor reading command to not use the bit by default in the operation field which triggers the BMC to overwrite the existing assertion mask. -Updated the reboot count sensor to use the operation specified by AMI to overwrite existing data in assertion mask field. Fixes open-power/hostboot#47 Change-Id: I81958225480f495f8b0d4f523d0c8109832475f6 CQ:SW328073 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/23947 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/ipmi')
-rw-r--r--src/usr/ipmi/ipmisensor.C18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/usr/ipmi/ipmisensor.C b/src/usr/ipmi/ipmisensor.C
index 69a58dd95..4aa1c9f4b 100644
--- a/src/usr/ipmi/ipmisensor.C
+++ b/src/usr/ipmi/ipmisensor.C
@@ -546,6 +546,7 @@ namespace SENSOR
:SensorBase(TARGETING::SENSOR_NAME_REBOOT_COUNT, NULL)
{
// message buffer created and initialized in base object.
+
}
//
@@ -558,6 +559,9 @@ namespace SENSOR
//
errlHndl_t RebootCountSensor::setRebootCount( uint16_t i_count )
{
+ // adjust the operation to overwrite the sensor reading
+ // to the value we send.
+ iv_msg->iv_operation = SET_SENSOR_VALUE_OPERATION;
// the Reboot_count sensor is defined as a discrete sensor
// but the assertion bytes are being used to transfer the count
@@ -659,8 +663,9 @@ namespace SENSOR
case NOT_PRESENT:
// turn off the present bit
iv_msg->iv_deassertion_mask = pres_mask;
- // turn on the disabled bit
- iv_msg->iv_assertion_mask = func_mask;
+
+ // turn off the disabled bit in case it was on
+ iv_msg->iv_deassertion_mask |= func_mask;
break;
case PRESENT:
@@ -795,6 +800,14 @@ namespace SENSOR
// assert the specified state
iv_msg->iv_assertion_mask = setMask(i_state);
+ // there are two offsets used with this sensor, when
+ // asserting one, we need to deassert the other as only
+ // one state is valid at any given time.
+ OccStateEnum other_state =
+ (i_state == OCC_ACTIVE) ? OCC_NOT_ACTIVE : OCC_ACTIVE;
+
+ iv_msg->iv_deassertion_mask = setMask( other_state );
+
l_err = writeSensorData();
return l_err;
@@ -858,6 +871,7 @@ namespace SENSOR
//
errlHndl_t HostStatusSensor::updateHostStatus( hostStatus status )
{
+ iv_msg->iv_operation = SET_SENSOR_VALUE_OPERATION;
iv_msg->iv_assertion_mask = setMask((uint8_t)status);
return writeSensorData();
OpenPOWER on IntegriCloud