summaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/lm90.c
diff options
context:
space:
mode:
authorGuenter Roeck <linux@roeck-us.net>2016-07-25 23:47:18 +0200
committerGuenter Roeck <linux@roeck-us.net>2016-08-01 00:01:06 +0200
commitbe9d6374a76ffbeda783a5bdcb00e219c7bda2d0 (patch)
tree75e7a87b1cf772c0bce570b9db773d7b5aafce34 /drivers/hwmon/lm90.c
parenthwmon: (sht3x) set initial jiffies to last_update (diff)
downloadlinux-be9d6374a76ffbeda783a5bdcb00e219c7bda2d0.tar.xz
linux-be9d6374a76ffbeda783a5bdcb00e219c7bda2d0.zip
hwmon: (lm90) Add missing assignment
Coverity reports the following error. >>> CID 1364474: Error handling issues (CHECKED_RETURN) >>> Calling "lm90_read_reg" without checking return value (as is done >>> elsewhere 28 out of 29 times). 532 lm90_read_reg(client, LM90_REG_R_REMOTE_LOWH); 533 if (val < 0) 534 return val; Fixes: 10bfef47bd259 ("hwmon: (lm90) Read limit registers only once") Reviewed-by: Jean Delvare <jdelvare@suse.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon/lm90.c')
-rw-r--r--drivers/hwmon/lm90.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/lm90.c b/drivers/hwmon/lm90.c
index f51e758ba529..7b3eedf76c62 100644
--- a/drivers/hwmon/lm90.c
+++ b/drivers/hwmon/lm90.c
@@ -529,7 +529,7 @@ static int lm90_update_limits(struct device *dev)
return val;
data->temp_hyst = val;
- lm90_read_reg(client, LM90_REG_R_REMOTE_LOWH);
+ val = lm90_read_reg(client, LM90_REG_R_REMOTE_LOWH);
if (val < 0)
return val;
data->temp11[REMOTE_LOW] = val << 8;