This is a note to let you know that I've just added the patch titled pwm: Fix setting period with #pwm-cells = <1> and of_pwm_single_xlate() to the 6.8-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: pwm-fix-setting-period-with-pwm-cells-1-and-of_pwm_s.patch and it can be found in the queue-6.8 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit 19f8db5c9d2cd4ee3bb40dcefa1b19134c5fba82 Author: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> Date: Fri Mar 29 11:35:40 2024 +0100 pwm: Fix setting period with #pwm-cells = <1> and of_pwm_single_xlate() [ Upstream commit 73dfe970c038d0548beccc5bfb2707e1d543b01f ] For drivers making use of of_pwm_single_xlate() (i.e. those that don't pass a hwpwm index) and also don't pass flags, setting period was wrongly skipped. This affects the pwm-pxa and ti-sn65dsi86 drivers. Reported-by: Karel Balej <balejk@xxxxxxxxx> Link: https://lore.kernel.org/r/D05IVTPYH35N.2CLDG6LSILRSN@xxxxxxxxx Fixes: 40ade0c2e794 ("pwm: Let the of_xlate callbacks accept references without period") Tested-by: Karel Balej <balejk@xxxxxxxxx> Link: https://lore.kernel.org/r/20240329103544.545290-2-u.kleine-koenig@xxxxxxxxxxxxxx Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c index 830a697826af5..9d2dc5e1c8aac 100644 --- a/drivers/pwm/core.c +++ b/drivers/pwm/core.c @@ -443,7 +443,7 @@ of_pwm_single_xlate(struct pwm_chip *chip, const struct of_phandle_args *args) if (IS_ERR(pwm)) return pwm; - if (args->args_count > 1) + if (args->args_count > 0) pwm->args.period = args->args[0]; pwm->args.polarity = PWM_POLARITY_NORMAL;