• Vladimir Zapolskiy's avatar
    watchdog: fix compile time error of pretimeout governors · a223770b
    Vladimir Zapolskiy authored
    CONFIG_WATCHDOG_PRETIMEOUT_GOV build symbol adds watchdog_pretimeout.o
    object to watchdog.o, the latter is compiled only if CONFIG_WATCHDOG_CORE
    is selected, so it rightfully makes sense to add it as a dependency.
    
    The change fixes the next compilation errors, if CONFIG_WATCHDOG_CORE=n
    and CONFIG_WATCHDOG_PRETIMEOUT_GOV=y are selected:
    
      drivers/watchdog/pretimeout_noop.o: In function `watchdog_gov_noop_register':
      drivers/watchdog/pretimeout_noop.c:35: undefined reference to `watchdog_register_governor'
      drivers/watchdog/pretimeout_noop.o: In function `watchdog_gov_noop_unregister':
      drivers/watchdog/pretimeout_noop.c:40: undefined reference to `watchdog_unregister_governor'
    
      drivers/watchdog/pretimeout_panic.o: In function `watchdog_gov_panic_register':
      drivers/watchdog/pretimeout_panic.c:35: undefined reference to `watchdog_register_governor'
      drivers/watchdog/pretimeout_panic.o: In function `watchdog_gov_panic_unregister':
      drivers/watchdog/pretimeout_panic.c:40: undefined reference to `watchdog_unregister_governor'
    Reported-by: default avatarKuo, Hsuan-Chi <hckuo2@illinois.edu>
    Fixes: ff84136c ("watchdog: add watchdog pretimeout governor framework")
    Signed-off-by: default avatarVladimir Zapolskiy <vz@mleia.com>
    Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Signed-off-by: default avatarWim Van Sebroeck <wim@linux-watchdog.org>
    a223770b
Kconfig 64.2 KB