lkml.org 
[lkml]   [2020]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4.19 366/639] pwm: meson: Dont disable PWM when setting duty repeatedly
    Date
    From: Bichao Zheng <bichao.zheng@amlogic.com>

    [ 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>
    ---
    drivers/pwm/pwm-meson.c | 5 -----
    1 file changed, 5 deletions(-)

    diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c
    index 4b708c1fcb1d2..e247ab632530b 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);
    --
    2.20.1


    \
     
     \ /
      Last update: 2020-01-24 12:20    [W:2.703 / U:0.692 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site