diff --git a/xCAT-server/lib/xcat/plugins/openbmc.pm b/xCAT-server/lib/xcat/plugins/openbmc.pm index 0a513e2d9..d67cf7ca1 100644 --- a/xCAT-server/lib/xcat/plugins/openbmc.pm +++ b/xCAT-server/lib/xcat/plugins/openbmc.pm @@ -1220,7 +1220,14 @@ sub rvitals_response { # $key_url is "/xyz/openbmc_project/sensors/xxx/yyy # For now display xxx/yyy as a label my ($junk, $label) = split("/sensors/", $key_url); - $sensor_value = $label . ": " . $content{Value} . " " . $sensor_units{ $content{Unit} }; + # + # Calculate the value based on the scale + # + my $calc_value = $content{Value}; + if ( $content{Scale} != 0 ) { + $calc_value = ($content{Value} * (10 ** $content{Scale})); + } + $sensor_value = $label . ": " . $calc_value . " " . $sensor_units{ $content{Unit} }; xCAT::SvrUtils::sendmsg("$sensor_value", $callback, $node); }