[PATCH v3] pwm: imx-tpm: Use correct MODULO value for EPWM mode
Uwe Kleine-König
u.kleine-koenig at baylibre.com
Fri Oct 25 02:51:24 PDT 2024
Hello,
On Fri, Oct 25, 2024 at 08:37:00AM +0000, Erik Schumacher wrote:
> The modulo register defines the period of the edge-aligned PWM mode
> (which is the only mode implemented). The reference manual states:
> "The EPWM period is determined by (MOD + 0001h) ..." So the value that
> is written to the MOD register must therefore be one less than the
> calculated period length. Return -EINVAL if the calculated length is
> already zero.
> A correct MODULO value is particularly relevant if the PWM has to output
> a high frequency due to a low period value.
>
> Fixes: 738a1cfec2ed ("pwm: Add i.MX TPM PWM driver support")
> Cc: stable at vger.kernel.org
> Signed-off-by: Erik Schumacher <erik.schumacher at iris-sensing.com>
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/ukleinek/linux.git pwm/fixes
I let it sit there for a few days to get some coverage in next and then
intend to send it to Linus for mainline inclusion ~ mid of next week.
Best regards
Uwe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20241025/3429379b/attachment.sig>
More information about the linux-arm-kernel
mailing list