diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2013-09-11 00:19:52 -0400 |
---|---|---|
committer | Guenter Roeck <linux@roeck-us.net> | 2013-09-11 16:01:41 -0400 |
commit | 010a166a5202f6297e196624a0671c4815032e38 (patch) | |
tree | 6288f8a7c035ff17a3d8e465c65d00b505ff6134 /drivers/hwmon | |
parent | 17a52100b03864b5e58fb45ec6b42d4fd81c4808 (diff) |
hwmon: (tmp421) Fix return value
Propagate return value obtained from i2c_smbus_read_byte_data()
instead of hardcoding.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Andre Prendel <andre.prendel@gmx.de>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon')
-rw-r--r-- | drivers/hwmon/tmp421.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/tmp421.c b/drivers/hwmon/tmp421.c index 964c1d688274..ae26b06fa819 100644 --- a/drivers/hwmon/tmp421.c +++ b/drivers/hwmon/tmp421.c | |||
@@ -210,7 +210,7 @@ static int tmp421_init_client(struct i2c_client *client) | |||
210 | if (config < 0) { | 210 | if (config < 0) { |
211 | dev_err(&client->dev, | 211 | dev_err(&client->dev, |
212 | "Could not read configuration register (%d)\n", config); | 212 | "Could not read configuration register (%d)\n", config); |
213 | return -ENODEV; | 213 | return config; |
214 | } | 214 | } |
215 | 215 | ||
216 | config_orig = config; | 216 | config_orig = config; |