pwm: stm32: remove automatic output enable
diff mbox series

Message ID 1574333880-29339-1-git-send-email-fabrice.gasnier@st.com
State Accepted
Commit 0c73201c5c094256236b129799ab6761b491d8cd
Headers show
Series
  • pwm: stm32: remove automatic output enable
Related show

Commit Message

Fabrice Gasnier Nov. 21, 2019, 10:58 a.m. UTC
Don't use AOE (automatic output enable) by default.
In case of break events, pwm is automatically re-enabled on next pwm
cycle otherwise.

Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com>
---
 drivers/pwm/pwm-stm32.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Patch
diff mbox series

diff --git a/drivers/pwm/pwm-stm32.c b/drivers/pwm/pwm-stm32.c
index 359b085..3079818 100644
--- a/drivers/pwm/pwm-stm32.c
+++ b/drivers/pwm/pwm-stm32.c
@@ -374,9 +374,7 @@  static int stm32_pwm_config(struct stm32_pwm *priv, int ch,
 	else
 		regmap_update_bits(priv->regmap, TIM_CCMR2, mask, ccmr);
 
-	regmap_update_bits(priv->regmap, TIM_BDTR,
-			   TIM_BDTR_MOE | TIM_BDTR_AOE,
-			   TIM_BDTR_MOE | TIM_BDTR_AOE);
+	regmap_update_bits(priv->regmap, TIM_BDTR, TIM_BDTR_MOE, TIM_BDTR_MOE);
 
 	return 0;
 }