[PATCH] watchdog: rti_wdt: Allow timeout config with timeout-sec

From: Judith Mendez
Date: Wed Aug 21 2024 - 16:20:02 EST


Currently rti_wdt does not allow timeout to be configured
via DT property timeout-sec, so fix watchdog_init_timeout
to be able to use timeout-sec.

Signed-off-by: Judith Mendez <jm@xxxxxx>
---
drivers/watchdog/rti_wdt.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/watchdog/rti_wdt.c b/drivers/watchdog/rti_wdt.c
index 8e1be7ba01039..7260c67e60a25 100644
--- a/drivers/watchdog/rti_wdt.c
+++ b/drivers/watchdog/rti_wdt.c
@@ -332,7 +332,8 @@ static int rti_wdt_probe(struct platform_device *pdev)
memunmap(vaddr);
}

- watchdog_init_timeout(wdd, heartbeat, dev);
+ wdd->timeout = heartbeat;
+ watchdog_init_timeout(wdd, 0, dev);

ret = watchdog_register_device(wdd);
if (ret) {

base-commit: 860bbe8e618fd62446309e286ab4a83d38201c0a
--
2.46.0