We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4ed224a commit ffd264bCopy full SHA for ffd264b
drivers/watchdog/msc313e_wdt.c
@@ -120,6 +120,10 @@ static int msc313e_wdt_probe(struct platform_device *pdev)
120
priv->wdev.max_timeout = U32_MAX / clk_get_rate(priv->clk);
121
priv->wdev.timeout = MSC313E_WDT_DEFAULT_TIMEOUT;
122
123
+ /* If the period is non-zero the WDT is running */
124
+ if (readw(priv->base + REG_WDT_MAX_PRD_L) | (readw(priv->base + REG_WDT_MAX_PRD_H) << 16))
125
+ set_bit(WDOG_HW_RUNNING, &priv->wdev.status);
126
+
127
watchdog_set_drvdata(&priv->wdev, priv);
128
129
watchdog_init_timeout(&priv->wdev, timeout, dev);
0 commit comments