diff options
author | Alex Hemme <ahemme@cisco.com> | 2017-03-07 22:38:29 +0300 |
---|---|---|
committer | Guenter Roeck <linux@roeck-us.net> | 2017-03-22 10:18:20 +0300 |
commit | dd7406dd334a98ada3ff5371847a3eeb4ba16313 (patch) | |
tree | 3b9e729931054dc961a422629086ba6011fcb243 /drivers/hwmon/max31790.c | |
parent | 97da3854c526d3a6ee05c849c96e48d21527606c (diff) | |
download | linux-dd7406dd334a98ada3ff5371847a3eeb4ba16313.tar.xz |
hwmon: (max31790) Set correct PWM value
Traced fans not spinning to incorrect PWM value being written.
The passed in value was written instead of the calulated value.
Fixes: 54187ff9d766 ("hwmon: (max31790) Convert to use new hwmon registration API")
Signed-off-by: Alex Hemme <ahemme@cisco.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon/max31790.c')
-rw-r--r-- | drivers/hwmon/max31790.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/max31790.c b/drivers/hwmon/max31790.c index c1b9275978f9..281491cca510 100644 --- a/drivers/hwmon/max31790.c +++ b/drivers/hwmon/max31790.c @@ -311,7 +311,7 @@ static int max31790_write_pwm(struct device *dev, u32 attr, int channel, data->pwm[channel] = val << 8; err = i2c_smbus_write_word_swapped(client, MAX31790_REG_PWMOUT(channel), - val); + data->pwm[channel]); break; case hwmon_pwm_enable: fan_config = data->fan_config[channel]; |