Commit d7971d57 authored by Cristian Marussi's avatar Cristian Marussi Committed by Sudeep Holla

hwmon: (scmi) Update hwmon internal scale data type

Use an int to calculate scale values inside scmi_hwmon_scale() to match
the updated scale data type in struct scmi_sensor_info.

Link: https://lore.kernel.org/r/20201119174906.43862-4-cristian.marussi@arm.com
Cc: linux-hwmon@vger.kernel.org
Acked-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarCristian Marussi <cristian.marussi@arm.com>
Signed-off-by: default avatarSudeep Holla <sudeep.holla@arm.com>
parent 1fe00b8b
...@@ -30,7 +30,7 @@ static inline u64 __pow10(u8 x) ...@@ -30,7 +30,7 @@ static inline u64 __pow10(u8 x)
static int scmi_hwmon_scale(const struct scmi_sensor_info *sensor, u64 *value) static int scmi_hwmon_scale(const struct scmi_sensor_info *sensor, u64 *value)
{ {
s8 scale = sensor->scale; int scale = sensor->scale;
u64 f; u64 f;
switch (sensor->type) { switch (sensor->type) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment