diff mbox series

[RESEND,v5,4/9] pwm: pxa: populate PWM mode in of_xlate function

Message ID 1535461286-12308-5-git-send-email-claudiu.beznea@microchip.com (mailing list archive)
State New, archived
Headers show
Series extend PWM framework to support PWM modes | expand

Commit Message

Claudiu Beznea Aug. 28, 2018, 1:01 p.m. UTC
Populate PWM mode in of_xlate function to avoid pwm_apply_state() failure.

Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
---
 drivers/pwm/pwm-pxa.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/drivers/pwm/pwm-pxa.c b/drivers/pwm/pwm-pxa.c
index 4143a46684d2..4c88cb47d6ba 100644
--- a/drivers/pwm/pwm-pxa.c
+++ b/drivers/pwm/pwm-pxa.c
@@ -161,6 +161,7 @@  pxa_pwm_of_xlate(struct pwm_chip *pc, const struct of_phandle_args *args)
 		return pwm;
 
 	pwm->args.period = args->args[0];
+	pwm->args.mode = pwm_mode_get_valid(pc, pwm);
 
 	return pwm;
 }