#include <linux/clk.h>
#include <linux/io.h>
#include <linux/module.h>
#include <linux/mod_devicetable.h>
#include <linux/platform_device.h>
#include <linux/reset.h>
#include <linux/watchdog.h>
#define WDT_CTRL …
#define WDT_CNT …
#define WDT_STOP …
#define WDT_RESUME …
#define WDT_CLRIRQ …
#define WDT_UNLOCK …
#define WDT_LOCK …
#define WDT_CONMAX …
#define SP_WDT_MAX_TIMEOUT …
#define SP_WDT_DEFAULT_TIMEOUT …
#define STC_CLK …
#define DEVICE_NAME …
static unsigned int timeout;
module_param(timeout, int, 0);
MODULE_PARM_DESC(…) …;
static bool nowayout = … WATCHDOG_NOWAYOUT;
module_param(nowayout, bool, 0);
MODULE_PARM_DESC(…) …;
struct sp_wdt_priv { … };
static int sp_wdt_restart(struct watchdog_device *wdev,
unsigned long action, void *data)
{ … }
static int sp_wdt_ping(struct watchdog_device *wdev)
{ … }
static int sp_wdt_stop(struct watchdog_device *wdev)
{ … }
static int sp_wdt_start(struct watchdog_device *wdev)
{ … }
static unsigned int sp_wdt_get_timeleft(struct watchdog_device *wdev)
{ … }
static const struct watchdog_info sp_wdt_info = …;
static const struct watchdog_ops sp_wdt_ops = …;
static void sp_reset_control_assert(void *data)
{ … }
static int sp_wdt_probe(struct platform_device *pdev)
{ … }
static const struct of_device_id sp_wdt_of_match[] = …;
MODULE_DEVICE_TABLE(of, sp_wdt_of_match);
static struct platform_driver sp_wdt_driver = …;
module_platform_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;