All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCHv2 0/2] pwm: sunxi: give the pwm IP block more time
@ 2016-08-25 17:50 ` Olliver Schinagl
  0 siblings, 0 replies; 39+ messages in thread
From: Olliver Schinagl @ 2016-08-25 17:50 UTC (permalink / raw)
  To: Alexandre Belloni, Thierry Reding, Maxime Ripard, Chen-Yu Tsai
  Cc: linux-pwm, linux-arm-kernel, linux-kernel, Olliver Schinagl

Hi all,

last year I've sent out this patch series and there was little technical
discussion, so hopefully we can rekindle it.

This patch series fixes 2 issues. For one, we add a delay between disabling
the PWM hardware block and removing the clock, this to yield the PWM hardware
time to actually finish it's PWM and finish in the proper state. If we do not
do this, the output may stay high and may overload speakers for example.

The other issue might need a little more discussion. It also yields the PWM
hardware some extra time. When changing the config, we enable the clock
together with the parameters for the PWM. Sometimes however, the PWM IP core
has not had the time yet to actually set the ready bit. By first enabling
the gate, and then change things, the IP has time to do its thing. The PWM
block has probably done its thing even after the writel has returned. So an
extra delay (of one bus clock cycle?) is overkill.

Changes since v1:
	- Split patch series into several smaller patch series
	- Added driver author

Olliver Schinagl (2):
  pwm: sunxi: allow the pwm to finish its pulse before disable
  pwm: sunxi: Yield some time to the pwm-block to become ready

 drivers/pwm/pwm-sun4i.c | 54 ++++++++++++++++++++++++++++++++-----------------
 1 file changed, 36 insertions(+), 18 deletions(-)

-- 
2.8.1

^ permalink raw reply	[flat|nested] 39+ messages in thread

end of thread, other threads:[~2017-05-05  1:54 UTC | newest]

Thread overview: 39+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-25 17:50 [PATCHv2 0/2] pwm: sunxi: give the pwm IP block more time Olliver Schinagl
2016-08-25 17:50 ` Olliver Schinagl
2016-08-25 17:50 ` [PATCH 1/2] pwm: sunxi: allow the pwm to finish its pulse before disable Olliver Schinagl
2016-08-25 17:50   ` Olliver Schinagl
2016-08-26 22:19   ` Maxime Ripard
2016-08-26 22:19     ` Maxime Ripard
2016-09-06  7:12     ` Olliver Schinagl
2016-09-06  7:12       ` Olliver Schinagl
2016-09-06 19:51       ` Maxime Ripard
2016-09-06 19:51         ` Maxime Ripard
2016-09-09  9:01         ` Olliver Schinagl
2016-09-09  9:01           ` Olliver Schinagl
2016-09-24 20:25           ` Maxime Ripard
2016-09-24 20:25             ` Maxime Ripard
2016-09-26  8:46             ` Olliver Schinagl
2016-09-26  8:46               ` Olliver Schinagl
2016-09-27 20:16               ` Maxime Ripard
2016-09-27 20:16                 ` Maxime Ripard
2016-12-08 13:23     ` Olliver Schinagl
2016-12-12 12:24       ` Maxime Ripard
2016-12-12 12:24         ` Maxime Ripard
2017-01-03 15:59         ` Olliver Schinagl
2017-01-03 15:59           ` Olliver Schinagl
2017-01-03 16:55           ` Alexandre Belloni
2017-01-03 16:55             ` Alexandre Belloni
2017-01-03 16:55             ` Alexandre Belloni
2017-01-04  6:36             ` Thierry Reding
2017-01-04  6:36               ` Thierry Reding
2017-01-04  6:36               ` Thierry Reding
2016-09-23 14:02   ` [1/2] " Jonathan Liu
2016-09-23 14:02     ` Jonathan Liu
2016-09-23 14:03     ` Olliver Schinagl
2016-09-23 14:03       ` Olliver Schinagl
2017-05-05  1:54       ` Jonathan Liu
2017-05-05  1:54         ` Jonathan Liu
2016-08-25 17:50 ` [PATCH 2/2] pwm: sunxi: Yield some time to the pwm-block to become ready Olliver Schinagl
2016-08-25 17:50   ` Olliver Schinagl
2016-08-26 22:25   ` Maxime Ripard
2016-08-26 22:25     ` Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.