[PATCH v6 2/5] watchdog: s3c2410_wdt: Fix max_timeout being calculated larger

Alim Akhtar alim.akhtar at samsung.com
Wed Sep 17 20:41:47 PDT 2025


Hi Sangwook

> -----Original Message-----
> From: Sangwook Shin <sw617.shin at samsung.com>
> Sent: Monday, August 18, 2025 7:48 AM
> To: krzk at kernel.org; alim.akhtar at samsung.com; wim at linux-watchdog.org;
> linux at roeck-us.net; semen.protsenko at linaro.org;
> dongil01.park at samsung.com; khwan.seo at samsung.com
> Cc: linux-arm-kernel at lists.infradead.org; linux-samsung-soc at vger.kernel.org;
> linux-watchdog at vger.kernel.org; linux-kernel at vger.kernel.org; Sangwook Shin
> <sw617.shin at samsung.com>
> Subject: [PATCH v6 2/5] watchdog: s3c2410_wdt: Fix max_timeout being
> calculated larger
> 
> Fix the issue of max_timeout being calculated larger than actual value.
> The calculation result of freq / (S3C2410_WTCON_PRESCALE_MAX + 1) /
> S3C2410_WTCON_MAXDIV is smaller than the actual value because the
> remainder is discarded during the calculation process. This leads to a larger
> calculated value for max_timeout compared to the actual settable value.
> To resolve this issue, the order of calculations in the computation process has
> been adjusted.
> 
> Reviewed-by: Sam Protsenko <semen.protsenko at linaro.org>
> Signed-off-by: Sangwook Shin <sw617.shin at samsung.com>
> ---
Reviewed-by: Alim Akhtar <alim.akhtar at samsung.com>






More information about the linux-arm-kernel mailing list