summaryrefslogtreecommitdiffstats
path: root/drivers/ras/cec.c
diff options
context:
space:
mode:
authorGuenter Roeck <linux@roeck-us.net>2019-06-07 10:23:17 -0700
committerGuenter Roeck <linux@roeck-us.net>2019-06-23 18:33:01 -0700
commitb2905bb8e1f3764c21e449931f3fb75405f7d41e (patch)
treed880eee8fda6e9b52f252c002a5e17209785a2b3 /drivers/ras/cec.c
parent8e5e7ddd38b69ef48a2104cd663fab0e3dd03e14 (diff)
downloadlinux-b2905bb8e1f3764c21e449931f3fb75405f7d41e.tar.bz2
hwmon: (max6650) Introduce pwm_to_dac and dac_to_pwm
Consolidate conversion from pwm value to dac value and from dac value to pwm value into helper functions. While doing this, only update the cached dac value if writing it to the chip was successful after an update. Also, put macro argument of DIV_FROM_REG() into (), and simplify return statement of max6650_set_cur_state(). Cc: Jean-Francois Dagenais <jeff.dagenais@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/ras/cec.c')
0 files changed, 0 insertions, 0 deletions