hwmon: (pwm-fan) Simplify enable/disable check

Instead of comparing the current to the new pwm duty to decide whether to
enable the PWM, use a dedicated flag. Also apply the new PWM duty in any
case. This is a preparation to enable/disable the regulator dynamically.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
Link: https://lore.kernel.org/r/20220914153137.613982-3-alexander.stein@ew.tq-group.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
Alexander Stein 2022-09-14 17:31:34 +02:00 • committed by Guenter Roeck
commit b77f0c7680