summaryrefslogtreecommitdiffstats
path: root/drivers/pwm
diff options
context:
space:
mode:
authorBichao Zheng <bichao.zheng@amlogic.com>2019-04-01 20:18:17 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-01-27 14:50:47 +0100
commite2db9f3a36eb12860135b07f37fb181172998c1f (patch)
tree4923a0cf5b6fac9dec2c831fef290d534ce5779d /drivers/pwm
parent8d029e818d2dfb59de03b22924bd7d8b731a649f (diff)
downloadlinux-stable-e2db9f3a36eb12860135b07f37fb181172998c1f.tar.gz
linux-stable-e2db9f3a36eb12860135b07f37fb181172998c1f.tar.bz2
linux-stable-e2db9f3a36eb12860135b07f37fb181172998c1f.zip
pwm: meson: Don't disable PWM when setting duty repeatedly
[ Upstream commit a279345807e1e0ae79567a52cfdd9d30c9174a3c ] There is an abnormally low about 20ms,when setting duty repeatedly. Because setting the duty will disable PWM and then enable. Delete this operation now. Fixes: 211ed630753d2f ("pwm: Add support for Meson PWM Controller") Signed-off-by: Bichao Zheng <bichao.zheng@amlogic.com> [ Dropped code instead of hiding it behind a comment ] Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/pwm')
-rw-r--r--drivers/pwm/pwm-meson.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c
index 4b708c1fcb1d..e247ab632530 100644
--- a/drivers/pwm/pwm-meson.c
+++ b/drivers/pwm/pwm-meson.c
@@ -325,11 +325,6 @@ static int meson_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
if (state->period != channel->state.period ||
state->duty_cycle != channel->state.duty_cycle ||
state->polarity != channel->state.polarity) {
- if (channel->state.enabled) {
- meson_pwm_disable(meson, pwm->hwpwm);
- channel->state.enabled = false;
- }
-
if (state->polarity != channel->state.polarity) {
if (state->polarity == PWM_POLARITY_NORMAL)
meson->inverter_mask |= BIT(pwm->hwpwm);