Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: "Uwe Kleine-König" <ukleinek@kernel.org>
To: stable@vger.kernel.org
Cc: Alexander Sverdlin <alexander.sverdlin@siemens.com>
Subject: Re: [PATCH 6.6.y] pwm: tiehrpwm: Clear period on disable to allow reconfiguration
Date: Mon, 9 Nov 2026 09:26:37 +0100	[thread overview]
Message-ID: <avGDhwQFx9z_vj8V@monoceros> (raw)
In-Reply-To: <20261109081728.798045-2-ukleinek@kernel.org>

[-- Attachment #1: Type: text/plain, Size: 1315 bytes --]

Hello again,

On Mon, Nov 09, 2026 at 09:17:29AM +0100, Uwe Kleine-König wrote:
> From: Alexander Sverdlin <alexander.sverdlin@siemens.com>
> 
> [ Upstream commit e74b9a7ee50071aad25d3989bf985292f90b0c6e ]
> 
> Both channels share one period register, so ehrpwm_pwm_config() rejects a
> period differing from the sibling's period_cycles[]. That value was cleared
> only in .free(), not in .disable(), so a stopped channel kept blocking the
> sibling from switching to a new frequency. Clear it in .disable() too.
> 
> Testcase:
> 
>   cd /sys/class/pwm/pwmchip0; echo 0 > export; echo 1 > export
>   for p in pwm0 pwm1; do
>     echo 1000000 > $p/period; echo 500000 > $p/duty_cycle
>     echo 1 > $p/enable; echo 0 > $p/enable; echo 2000000 > $p/period
>   done
>   echo 1 > pwm0/enable	# before: -EINVAL, after: succeeds
> 
> Fixes: 01b2d4536f02 ("pwm: pwm-tiehrpwm: Fix conflicting channel period setting")
> Cc: stable@vger.kernel.org
> Signed-off-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
> Link: https://patch.msgid.link/20260929120806.2790355-1-alexander.sverdlin@siemens.com
> Signed-off-by: Uwe Kleine-König <ukleinek@kernel.org>

I forgot to mention, this patch also applies to v5.10.x, so I assume
this patch is fine also for 6.1 and 5.15.

Best regards
Uwe

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2026-11-09  8:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-07 10:30 FAILED: patch "[PATCH] pwm: tiehrpwm: Clear period on disable to allow reconfiguration" failed to apply to 6.6-stable tree Sasha Levin
2026-11-09  8:17 ` [PATCH 6.6.y] pwm: tiehrpwm: Clear period on disable to allow reconfiguration Uwe Kleine-König
2026-11-09  8:26   ` Uwe Kleine-König [this message]
2026-11-09 15:53   ` Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=avGDhwQFx9z_vj8V@monoceros \
    --to=ukleinek@kernel.org \
    --cc=alexander.sverdlin@siemens.com \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox