[PATCH] pwm: pwm-meson: fix handling of period/duty if greater than UINT_MAX
Uwe Kleine-König
u.kleine-koenig at pengutronix.de
Wed May 3 13:24:35 PDT 2023
hello,
On Wed, May 03, 2023 at 09:58:17PM +0200, Heiner Kallweit wrote:
> state->period/duty are of type u64, and if their value is greater than
> UINT_MAX, then the cast to uint will cause problems. Fix this by
> changing the type of the respective local variables to u64.
>
> Fixes: b79c3670e120 ("pwm: meson: Don't duplicate the polarity internally")
> Cc: stable at vger.kernel.org
> Suggested-by: Uwe Kleine-König <u.kleine-koenig at pengutronix.de>
> Signed-off-by: Heiner Kallweit <hkallweit1 at gmail.com>
Reviewed-by: Uwe Kleine-König <u.kleine-koenig at pengutronix.de>
Thanks!
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
-------------- 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-amlogic/attachments/20230503/479c604d/attachment.sig>
More information about the linux-amlogic
mailing list