]> git.baikalelectronics.ru Git - kernel.git/commit
watchdog: Enforce that at least one pretimeout governor is enabled
authorGuenter Roeck <linux@roeck-us.net>
Wed, 8 May 2019 00:43:03 +0000 (17:43 -0700)
committerWim Van Sebroeck <wim@linux-watchdog.org>
Wed, 8 May 2019 08:33:59 +0000 (10:33 +0200)
commit4b41ddc79cfd8c5791aa6daa4128d315e8835d3d
treeca443725b2e580f2ea8b9acae6845c3f880f40d6
parent90ff841dd7fcb94515abe20e9c814a77c85d6a51
watchdog: Enforce that at least one pretimeout governor is enabled

Since commit "watchdog: Use depends instead of select for pretimeout
governors", it was possible to enable pretimeout governors but keep all
of them disabled. Doing this results in the following build failure.

../drivers/watchdog/watchdog_pretimeout.c:
In function ‘watchdog_register_governor’:
../drivers/watchdog/watchdog_pretimeout.c:139:26: error:
‘WATCHDOG_PRETIMEOUT_DEFAULT_GOV’ undeclared
   if (!strncmp(gov->name, WATCHDOG_PRETIMEOUT_DEFAULT_GOV,

Since it does not make sense to enable pretimeout support but disable
all pretimeout governors, enforce that at least one of them is always
enabled.

Fixes: 80ad0e7c3f69 ("watchdog: Use depends instead of select for pretimeout governors")
Reported-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
drivers/watchdog/Kconfig