• Claudiu Beznea's avatar
    pwm: atmel: Switch to atomic PWM · 1a722aad
    Claudiu Beznea authored
    The currently Atmel PWM controllers supported by this driver could
    change period or duty factor without channel disable, for regular
    channels (sama5d3 support this by using period or duty factor update
    registers, sam9rl support this by writing channel update register and
    select the corresponding update: period or duty factor). The chip
    doesn't support run time changings of signal polarity. To take advantage
    of atomic PWM framework and let controller works without glitches, in
    this patch only the duty factor could be changed without disabling PWM
    channel. For period and signal polarity the atomic PWM is simulated by
    disabling + enabling the right PWM channel.
    Signed-off-by: default avatarClaudiu Beznea <claudiu.beznea@microchip.com>
    Reviewed-by: default avatarBoris Brezillon <boris.brezillon@free-electrons.com>
    Signed-off-by: default avatarThierry Reding <thierry.reding@gmail.com>
    1a722aad
pwm-atmel.c 10.3 KB