linux/drivers/watchdog/sama5d4_wdt.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 * Driver for Atmel SAMA5D4 Watchdog Timer
 *
 * Copyright (C) 2015-2019 Microchip Technology Inc. and its subsidiaries
 */

#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/io.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/of_irq.h>
#include <linux/platform_device.h>
#include <linux/reboot.h>
#include <linux/watchdog.h>

#include "at91sam9_wdt.h"

/* minimum and maximum watchdog timeout, in seconds */
#define MIN_WDT_TIMEOUT
#define MAX_WDT_TIMEOUT
#define WDT_DEFAULT_TIMEOUT

#define WDT_SEC2TICKS(s)

struct sama5d4_wdt {};

static int wdt_timeout;
static bool nowayout = WATCHDOG_NOWAYOUT;

module_param(wdt_timeout, int, 0);
MODULE_PARM_DESC();

module_param(nowayout, bool, 0);
MODULE_PARM_DESC();

#define wdt_enabled

#define wdt_read(wdt, field)

/* 4 slow clock periods is 4/32768 = 122.07µs*/
#define WDT_DELAY

static void wdt_write(struct sama5d4_wdt *wdt, u32 field, u32 val)
{}

static void wdt_write_nosleep(struct sama5d4_wdt *wdt, u32 field, u32 val)
{}

static int sama5d4_wdt_start(struct watchdog_device *wdd)
{}

static int sama5d4_wdt_stop(struct watchdog_device *wdd)
{}

static int sama5d4_wdt_ping(struct watchdog_device *wdd)
{}

static int sama5d4_wdt_set_timeout(struct watchdog_device *wdd,
				 unsigned int timeout)
{}

static const struct watchdog_info sama5d4_wdt_info =;

static const struct watchdog_ops sama5d4_wdt_ops =;

static irqreturn_t sama5d4_wdt_irq_handler(int irq, void *dev_id)
{}

static int of_sama5d4_wdt_init(struct device_node *np, struct sama5d4_wdt *wdt)
{}

static int sama5d4_wdt_init(struct sama5d4_wdt *wdt)
{}

static int sama5d4_wdt_probe(struct platform_device *pdev)
{}

static const struct of_device_id sama5d4_wdt_of_match[] =;
MODULE_DEVICE_TABLE(of, sama5d4_wdt_of_match);

static int sama5d4_wdt_suspend_late(struct device *dev)
{}

static int sama5d4_wdt_resume_early(struct device *dev)
{}

static const struct dev_pm_ops sama5d4_wdt_pm_ops =;

static struct platform_driver sama5d4_wdt_driver =;
module_platform_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();