diff options
Diffstat (limited to 'drivers/watchdog/watchdog_pretimeout.c')
-rw-r--r-- | drivers/watchdog/watchdog_pretimeout.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/watchdog/watchdog_pretimeout.c b/drivers/watchdog/watchdog_pretimeout.c index c9e4a0326938..9db07bfb4334 100644 --- a/drivers/watchdog/watchdog_pretimeout.c +++ b/drivers/watchdog/watchdog_pretimeout.c @@ -52,6 +52,21 @@ static struct governor_priv *find_governor_by_name(const char *gov_name) return NULL; } +int watchdog_pretimeout_available_governors_get(char *buf) +{ + struct governor_priv *priv; + int count = 0; + + mutex_lock(&governor_lock); + + list_for_each_entry(priv, &governor_list, entry) + count += sprintf(buf + count, "%s\n", priv->gov->name); + + mutex_unlock(&governor_lock); + + return count; +} + int watchdog_pretimeout_governor_get(struct watchdog_device *wdd, char *buf) { int count = 0; |