(I'm so sorry!) Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

watchdog: digicolor: Avoid division by zero

clk_get_rate() could return 0. Avoid a division by zero panic. Since get_timeleft() cannot propagate errors, check the clock rate early in probe() and cache the rate in the driver data as it is unlikely to change at runtime. Fixes: 336694a01dae ("watchdog: digicolor: driver for Conexant Digicolor CX92755 SoC") Cc: stable@vger.kernel.org Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org> Acked-by: Baruch Siach <baruch@tkos.co.il> Link: https://patch.msgid.link/20260913064851.8239-2-tzungbi@kernel.org Signed-off-by: Guenter Roeck <linux@roeck-us.net>


Author Tzung-Bi Shih Committer Guenter Roeck Date Commit Parent 88f11363
+9 -4
1 changed file
+9 -4
1 changed file