diff options
author | Guenter Roeck <guenter.roeck@ericsson.com> | 2011-09-01 08:34:31 -0700 |
---|---|---|
committer | Guenter Roeck <guenter.roeck@ericsson.com> | 2011-10-24 11:09:39 -0700 |
commit | 179144a0d4128e7588b3d613a14807402f5e7c37 (patch) | |
tree | 996869256838ba759495d1a1331ffcddba94b1bd /drivers/hwmon/pmbus/max8688.c | |
parent | ced29d422557feb4230ea6b0067f1e24c5bd83f7 (diff) | |
download | op-kernel-dev-179144a0d4128e7588b3d613a14807402f5e7c37.zip op-kernel-dev-179144a0d4128e7588b3d613a14807402f5e7c37.tar.gz |
hwmon: (pmbus) Replace EINVAL return codes with more appropriate errors
EINVAL was over-used in the code. Replace it with more appropriate errors.
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Reviewed-by: Robert Coulson <robert.coulson@ericsson.com>
Diffstat (limited to 'drivers/hwmon/pmbus/max8688.c')
-rw-r--r-- | drivers/hwmon/pmbus/max8688.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/hwmon/pmbus/max8688.c b/drivers/hwmon/pmbus/max8688.c index e148e2c..7113f11 100644 --- a/drivers/hwmon/pmbus/max8688.c +++ b/drivers/hwmon/pmbus/max8688.c @@ -45,7 +45,7 @@ static int max8688_read_word_data(struct i2c_client *client, int page, int reg) int ret; if (page) - return -EINVAL; + return -ENXIO; switch (reg) { case PMBUS_VIRT_READ_VOUT_MAX: @@ -102,7 +102,7 @@ static int max8688_read_byte_data(struct i2c_client *client, int page, int reg) int mfg_status; if (page) - return -EINVAL; + return -ENXIO; switch (reg) { case PMBUS_STATUS_VOUT: |