linux/drivers/watchdog/watchdog_pretimeout.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * Copyright (C) 2015-2016 Mentor Graphics
 */

#include <linux/list.h>
#include <linux/slab.h>
#include <linux/spinlock.h>
#include <linux/string.h>
#include <linux/watchdog.h>

#include "watchdog_core.h"
#include "watchdog_pretimeout.h"

/* Default watchdog pretimeout governor */
static struct watchdog_governor *default_gov;

/* The spinlock protects default_gov, wdd->gov and pretimeout_list */
static DEFINE_SPINLOCK(pretimeout_lock);

/* List of watchdog devices, which can generate a pretimeout event */
static LIST_HEAD(pretimeout_list);

struct watchdog_pretimeout {};

/* The mutex protects governor list and serializes external interfaces */
static DEFINE_MUTEX(governor_lock);

/* List of the registered watchdog pretimeout governors */
static LIST_HEAD(governor_list);

struct governor_priv {};

static struct governor_priv *find_governor_by_name(const char *gov_name)
{}

int watchdog_pretimeout_available_governors_get(char *buf)
{}

int watchdog_pretimeout_governor_get(struct watchdog_device *wdd, char *buf)
{}

int watchdog_pretimeout_governor_set(struct watchdog_device *wdd,
				     const char *buf)
{}

void watchdog_notify_pretimeout(struct watchdog_device *wdd)
{}
EXPORT_SYMBOL_GPL();

int watchdog_register_governor(struct watchdog_governor *gov)
{}
EXPORT_SYMBOL();

void watchdog_unregister_governor(struct watchdog_governor *gov)
{}
EXPORT_SYMBOL();

int watchdog_register_pretimeout(struct watchdog_device *wdd)
{}

void watchdog_unregister_pretimeout(struct watchdog_device *wdd)
{}