Alexandre Belloni 8db9e29fe5 pwm: atmel: Fix polarity handling
When atmel_pwm_config() calculates and then sets the prescaler, it is
overwriting the channel's CMR register so we are losing the CPOL
configuration.

As atmel_pwm_config() is always called before enabling a channel,
inverting the polarity doesn't work.

Fix that by reading CMR first and only overwriting the prescaler bits.

Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
2014-03-18 20:47:31 +01:00
..
2014-03-18 20:47:31 +01:00
2013-06-12 13:18:29 +02:00
2013-12-12 13:23:23 +01:00
2014-01-21 08:28:00 +00:00
2013-06-12 13:18:29 +02:00
2014-02-26 16:14:57 +01:00
2013-06-12 13:18:29 +02:00
2013-10-08 15:45:44 +02:00