lkml.org 
[lkml]   [2015]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH 1/1] watchdog: fix watchdog_nmi_enable_all()
On Fri, Apr 17, 2015 at 11:26:36AM +0200, Ulrich Obergfell wrote:
> The 'watchdog_user_enabled' variable is only used as an 'interface'
> to the /proc/sys/kernel/watchdog parameter. The actual state of the
> watchdog is tracked by bits in the 'watchdog_enabled' variable. So,
> watchdog_nmi_enable_all() should check the NMI_WATCHDOG_ENABLED bit
> in 'watchdog_enabled'.

Looks good. I'll respin this and send to Andrew on Monday.

Cheers,
Don

>
> Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
> ---
> kernel/watchdog.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/watchdog.c b/kernel/watchdog.c
> index 2316f50..cba2110 100644
> --- a/kernel/watchdog.c
> +++ b/kernel/watchdog.c
> @@ -608,7 +608,7 @@ void watchdog_nmi_enable_all(void)
> {
> int cpu;
>
> - if (!watchdog_user_enabled)
> + if (!(watchdog_enabled & NMI_WATCHDOG_ENABLED))
> return;
>
> get_online_cpus();
> --
> 1.7.11.7
>


\
 
 \ /
  Last update: 2015-04-17 18:01    [W:0.055 / U:8.452 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site