[Skiboot] [PATCH V2] hw/ipmi-sensor: Fix setting of firmware progress sensor properly.
Stewart Smith
stewart at linux.vnet.ibm.com
Tue Nov 8 11:41:27 AEDT 2016
ppaidipe at linux.vnet.ibm.com writes:
> From: Pridhiviraj Paidipeddi <ppaidipe at linux.vnet.ibm.com>
>
> Currently Hostboot populates /bmc/sensors dt node and corresponding sensors
> only for BMC platforms, And for FSP platforms hostboot is not populating any
> fsp sensors(Management sensors) and also there is no firmware progress sensor
> exist in fsp platforms. Due to which OPAL incorrectly setting firmware status
> on a sensor id "00" which is not at all exist.
>
> On a FSP system:
> cat /sys/firmware/opal/msglog | grep -i setting
> [ 21.189204883,6] IPMI: setting fw progress sensor 00 to 07
> [ 21.189559121,6] IPMI: setting fw progress sensor 00 to 13
> cat /sys/firmware/opal/msglog | grep -i skiboot
> [ 84.127416495,5] SkiBoot skiboot-5.4.0-rc3 starting...
>
> On a BMC system:
> cat /sys/firmware/opal/msglog | grep -i setting
> [ 3.166286901,6] IPMI: setting fw progress sensor 05 to 14
> [ 14.259153338,6] IPMI: setting fw progress sensor 05 to 07
> [ 14.469070593,5] IPMI: Resetting boot count on successful boot
> [ 15.001210324,6] IPMI: setting fw progress sensor 05 to 13
>
> So this patch fixes this incorrect setting on a fsp system, and also sets the sensor
> only if OPAL initialises ipmi sensors and corresponding sensor exists for a given
> sensor type in the device tree.
>
> After patch:
> On a FSP system:
> cat /sys/firmware/opal/msglog | grep -i setting
>
> On a BMC system:
> cat /sys/firmware/opal/msglog | grep -i setting
> [ 3.164859816,6] IPMI: setting fw progress sensor 05 to 14
> [ 14.024941077,6] IPMI: setting fw progress sensor 05 to 07
> [ 14.211514767,5] IPMI: Resetting boot count on successful boot
> [ 14.252554375,6] IPMI: setting fw progress sensor 05 to 13
>
> Signed-off-by: Pridhiviraj Paidipeddi <ppaidipe at linux.vnet.ibm.com>
>
> Changes in V2:
> - Addressed the Joel's below suggestions
> - Added sensors_present variable to check ipmi sensors initialized.
> - Get the sensor ID only if sensor_type exist in the device tree.
> - Set the sensor reading only when sensor ID is received.
>
> Signed-off-by: Pridhiviraj Paidipeddi <ppaidipe at linux.vnet.ibm.com>
Thanks! merged with minor change to master as of 566150.
--
Stewart Smith
OPAL Architect, IBM.
More information about the Skiboot
mailing list