aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/generate_rust_target.rs
diff options
context:
space:
mode:
authorMike Crowe <[email protected]>2024-12-03 09:57:44 +0000
committerWim Van Sebroeck <[email protected]>2025-01-06 18:37:50 +0000
commit3322d53fdab8eedf01a9bca45dbf010566922e3c (patch)
treeab675d9f1f181fbac83aca34c6372988999e29d0 /scripts/generate_rust_target.rs
parentwatchdog: rti: Fix off-by-one in heartbeat recovery (diff)
downloadkernel-3322d53fdab8eedf01a9bca45dbf010566922e3c.tar.gz
kernel-3322d53fdab8eedf01a9bca45dbf010566922e3c.zip
watchdog: sp805: Report correct timeleft at maximum
sp805_wdt::load_val is of type unsigned int. When the interrupt is inactive wdt_timeleft adds one to the value, and then adds that to the value used to calculate the time remaining. Unfortunately it's not unlikely that load_val contains LOAD_MAX, which is 0xFFFFFFFF and wraps to zero when one is added to it, resulting in the time left being understated by about 21.7s. Fix this by ensuring the addition happens as 64-bit. Signed-off-by: Mike Crowe <[email protected]> Reviewed-by: Guenter Roeck <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]> Signed-off-by: Wim Van Sebroeck <[email protected]>
Diffstat (limited to 'scripts/generate_rust_target.rs')
0 files changed, 0 insertions, 0 deletions