summaryrefslogtreecommitdiffstats
path: root/drivers/pwm/pwm-lpss.c
diff options
context:
space:
mode:
authorClemens Gruber <clemens.gruber@pqgruber.com>2016-12-13 16:52:50 +0100
committerThierry Reding <thierry.reding@gmail.com>2017-01-20 07:43:22 +0100
commit8d254a340efb12b40c4c1ff25a48a4f48f7bbd6b (patch)
tree943df008c9e7718d8fba67687c4fb200cbd877f8 /drivers/pwm/pwm-lpss.c
parentb2ec9efc1f4fb1dc13a599db88019d5472deef9b (diff)
downloadlinux-8d254a340efb12b40c4c1ff25a48a4f48f7bbd6b.tar.bz2
pwm: pca9685: Fix period change with same duty cycle
When first implementing support for changing the output frequency, an optimization was added to continue the PWM after changing the prescaler without having to reprogram the ON and OFF registers for the duty cycle, in case the duty cycle stayed the same. This was flawed, because we compared the absolute value of the duty cycle in nanoseconds instead of the ratio to the period. Fix the problem by removing the shortcut. Fixes: 01ec8472009c9 ("pwm-pca9685: Support changing the output frequency") Cc: <stable@vger.kernel.org> # v4.3+ Signed-off-by: Clemens Gruber <clemens.gruber@pqgruber.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Diffstat (limited to 'drivers/pwm/pwm-lpss.c')
0 files changed, 0 insertions, 0 deletions