Lines Matching +full:timeout +full:- +full:enable
1 // SPDX-License-Identifier: GPL-2.0-only
26 #define VIA_WDT_CONF 0xec /* watchdog enable state */
29 #define VIA_WDT_CONF_ENABLE 0x01 /* 1: enable watchdog */
30 #define VIA_WDT_CONF_MMIO 0x02 /* 1: enable watchdog MMIO */
53 /* User space timeout in seconds */
56 static int timeout = WDT_TIMEOUT; variable
57 module_param(timeout, int, 0);
58 MODULE_PARM_DESC(timeout, "Watchdog timeout in seconds, between 1 and 1023 "
103 /* calculate when the next userspace timeout will be */ in wdt_ping()
104 next_heartbeat = jiffies + wdd->timeout * HZ; in wdt_ping()
112 writel(wdd->timeout, wdt_mem + VIA_WDT_COUNT); in wdt_start()
131 wdd->timeout = new_timeout; in wdt_set_timeout()
162 int ret = -ENODEV; in wdt_probe()
165 dev_err(&pdev->dev, "cannot enable PCI device\n"); in wdt_probe()
166 return -ENODEV; in wdt_probe()
177 dev_err(&pdev->dev, "MMIO allocation failed\n"); in wdt_probe()
188 dev_info(&pdev->dev, "VIA Chipset watchdog MMIO: %x\n", mmio); in wdt_probe()
190 dev_err(&pdev->dev, "MMIO setting failed. Check BIOS.\n"); in wdt_probe()
195 dev_err(&pdev->dev, "MMIO region busy\n"); in wdt_probe()
201 dev_err(&pdev->dev, "cannot remap VIA wdt MMIO registers\n"); in wdt_probe()
205 if (timeout < 1 || timeout > WDT_TIMEOUT_MAX) in wdt_probe()
206 timeout = WDT_TIMEOUT; in wdt_probe()
208 wdt_dev.timeout = timeout; in wdt_probe()
209 wdt_dev.parent = &pdev->dev; in wdt_probe()