diff options
author | Vivien Didelot <vivien.didelot@savoirfairelinux.com> | 2013-07-30 17:14:34 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-08-11 18:35:21 -0700 |
commit | 69325d97cb47677902ce3e873aeb1fe4abe7830f (patch) | |
tree | 4c58290c6c64b67e790a87f7ea2c327d19361f9c /drivers/hwmon/max6697.c | |
parent | 8a08a2ffd5719ed580862a2e525b8615a8b56a6d (diff) | |
download | linux-3.10-69325d97cb47677902ce3e873aeb1fe4abe7830f.tar.gz linux-3.10-69325d97cb47677902ce3e873aeb1fe4abe7830f.tar.bz2 linux-3.10-69325d97cb47677902ce3e873aeb1fe4abe7830f.zip |
hwmon: (max6697) fix MAX6581 ideality
commit 5c52add19733eb36d8619713312f5604efef3502 upstream.
Without this patch, the values for ideality (register 0x4b) and ideality
selection mask (register 0x4c) are inverted.
Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hwmon/max6697.c')
-rw-r--r-- | drivers/hwmon/max6697.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/hwmon/max6697.c b/drivers/hwmon/max6697.c index 328fb0353c1..a41b5f3fc50 100644 --- a/drivers/hwmon/max6697.c +++ b/drivers/hwmon/max6697.c @@ -605,12 +605,12 @@ static int max6697_init_chip(struct i2c_client *client) if (ret < 0) return ret; ret = i2c_smbus_write_byte_data(client, MAX6581_REG_IDEALITY, - pdata->ideality_mask >> 1); + pdata->ideality_value); if (ret < 0) return ret; ret = i2c_smbus_write_byte_data(client, MAX6581_REG_IDEALITY_SELECT, - pdata->ideality_value); + pdata->ideality_mask >> 1); if (ret < 0) return ret; } |