watchdog: aspeed: fix hardware timeout calculation
Subsystems (2)
PATCH 1/1 watchdog: aspeed: fix hardware timeout calculation
From: Tao Ren <[email protected]>
Fix hardware timeout calculation in aspeed_wdt_set_timeout function to ensure the reload value does not exceed the hardware limit.
--- drivers/watchdog/aspeed_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/watchdog/aspeed_wdt.c +1 -1
@@ -147,7 +147,7 @@ static int aspeed_wdt_set_timeout(struct watchdog_device *wdd, wdd->timeout = timeout; - actual =min (timeout, wdd->max_hw_heartbeat_ms *1000 ); + actual =min (timeout, wdd->max_hw_heartbeat_ms /1000 );writel (actual *WDT_RATE_1MHZ , wdt->base +WDT_RELOAD_VALUE );writel (WDT_RESTART_MAGIC , wdt->base +WDT_RESTART );
Signature · 1 line
2.17.1
Quoted 8 lines · rentao.bupt at gmail.com
From: Tao Ren <[email protected]>
Fix hardware timeout calculation in
aspeed_wdt_set_timeoutfunction to ensure the reload value does not exceed the hardware limit.Fixes efa859f7d786 ("watchdog: Add Aspeed watchdog driver")Reported-by Amithash Prasad <[email protected]>Signed-off-by Tao Ren <[email protected]>
Quoted 20 lines
--- drivers/watchdog/aspeed_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/watchdog/aspeed_wdt.c +1
-1@@ -147,7 +147,7 @@ static int aspeed_wdt_set_timeout(struct watchdog_device *wdd, wdd->timeout = timeout; - actual =min (timeout, wdd->max_hw_heartbeat_ms *1000 ); + actual =min (timeout, wdd->max_hw_heartbeat_ms /1000 );writel (actual *WDT_RATE_1MHZ , wdt->base +WDT_RELOAD_VALUE );writel (WDT_RESTART_MAGIC , wdt->base +WDT_RESTART );Signature · 1 line
2.17.1
Hi Wim,
Not sure if I looked at the wrong repository/branch, and looks like the patch is not included. Do you have any further suggestions? Or should I send out v2 in case it's missed?
Thanks,
Tao
Quoted 32 lines · Guenter Roeck
Quoted 8 lines · rentao.bupt at gmail.com
From: Tao Ren <[email protected]>
Fix hardware timeout calculation in
aspeed_wdt_set_timeoutfunction to ensure the reload value does not exceed the hardware limit.Fixes efa859f7d786 ("watchdog: Add Aspeed watchdog driver")Reported-by Amithash Prasad <[email protected]>Signed-off-by Tao Ren <[email protected]>Reviewed-by Guenter Roeck <[email protected]>Quoted 20 lines
--- drivers/watchdog/aspeed_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/watchdog/aspeed_wdt.c +1
-1@@ -147,7 +147,7 @@ static int aspeed_wdt_set_timeout(struct watchdog_device *wdd, wdd->timeout = timeout; - actual =min (timeout, wdd->max_hw_heartbeat_ms *1000 ); + actual =min (timeout, wdd->max_hw_heartbeat_ms /1000 );writel (actual *WDT_RATE_1MHZ , wdt->base +WDT_RELOAD_VALUE );writel (WDT_RESTART_MAGIC , wdt->base +WDT_RESTART );Signature · 1 line
2.17.1
Guenter Roeck
maintainerQuoted 6 lines · Tao Ren
Hi Wim,
Not sure if I looked at the wrong repository/branch, and looks like the patch is not included. Do you have any further suggestions? Or should I send out v2 in case it's missed?
Wim didn't send a pull request in this release cycle. I have the patch in my watchdog-next branch, so he'll hopefully pick it up from there at some point.
Resending the patch would just create noise at this point; please don't do that.
Guenter
Quoted 8 lines · Guenter Roeck
Quoted 6 lines · Tao Ren
Hi Wim,
Not sure if I looked at the wrong repository/branch, and looks like the patch is not included. Do you have any further suggestions? Or should I send out v2 in case it's missed?
Quoted 8 lines
Wim didn't send a pull request in this release cycle. I have the patch in my watchdog-next branch, so he'll hopefully pick it up from there at some point.
Resending the patch would just create noise at this point; please don't do that.
Guenter
Got it. Thanks Guenter.
- Tao