2014-11-04 22:34:23

by Anton Blanchard

[permalink] [raw]
Subject: Confusing behaviour with /proc/sys/kernel/nmi_watchdog


Hi,

commit 9919e39a1738 ("kvm: ensure hard lockup detection is disabled by
default") provided a way for the kernel to disable the hard lockup
detector at runtime.

I'm using it on ppc64 but notice some weird behaviour with the
nmi_watchdog procfs variable. At boot, that the hard lockup
detector appears to be enabled even when we disable it via
watchdog_enable_hardlockup_detector(false):

# cat /proc/sys/kernel/nmi_watchdog
1

I have to echo 0 to it then echo 1 again to enable it.

Anton


2014-11-05 10:26:56

by Andrew Jones

[permalink] [raw]
Subject: Re: Confusing behaviour with /proc/sys/kernel/nmi_watchdog

On Wed, Nov 05, 2014 at 09:34:20AM +1100, Anton Blanchard wrote:
>
> Hi,
>
> commit 9919e39a1738 ("kvm: ensure hard lockup detection is disabled by
> default") provided a way for the kernel to disable the hard lockup
> detector at runtime.
>
> I'm using it on ppc64 but notice some weird behaviour with the
> nmi_watchdog procfs variable. At boot, that the hard lockup
> detector appears to be enabled even when we disable it via
> watchdog_enable_hardlockup_detector(false):
>
> # cat /proc/sys/kernel/nmi_watchdog
> 1
>
> I have to echo 0 to it then echo 1 again to enable it.
>
> Anton

Hi Anton,

Yes, the nmi watchdog proc variables are currently a bit
confusing. Uli has posted a series to clear all that up
though. Please see

https://lkml.org/lkml/2014/10/17/340

drew

2014-11-05 14:54:03

by Don Zickus

[permalink] [raw]
Subject: Re: Confusing behaviour with /proc/sys/kernel/nmi_watchdog

On Wed, Nov 05, 2014 at 09:34:20AM +1100, Anton Blanchard wrote:
>
> Hi,
>
> commit 9919e39a1738 ("kvm: ensure hard lockup detection is disabled by
> default") provided a way for the kernel to disable the hard lockup
> detector at runtime.
>
> I'm using it on ppc64 but notice some weird behaviour with the
> nmi_watchdog procfs variable. At boot, that the hard lockup
> detector appears to be enabled even when we disable it via
> watchdog_enable_hardlockup_detector(false):
>
> # cat /proc/sys/kernel/nmi_watchdog
> 1
>
> I have to echo 0 to it then echo 1 again to enable it.

Hi Anton,

I believe Andrew answered the question for you, it's a WIP and we have
patches to clean that up.

I don't see ppc64 watchdog support in arch/powerpc, is that something you
are working with on implementing?

Cheers,
Don

2014-11-05 18:54:02

by Anton Blanchard

[permalink] [raw]
Subject: Re: Confusing behaviour with /proc/sys/kernel/nmi_watchdog


Hi Don,

> > commit 9919e39a1738 ("kvm: ensure hard lockup detection is disabled
> > by default") provided a way for the kernel to disable the hard
> > lockup detector at runtime.
> >
> > I'm using it on ppc64 but notice some weird behaviour with the
> > nmi_watchdog procfs variable. At boot, that the hard lockup
> > detector appears to be enabled even when we disable it via
> > watchdog_enable_hardlockup_detector(false):
> >
> > # cat /proc/sys/kernel/nmi_watchdog
> > 1
> >
> > I have to echo 0 to it then echo 1 again to enable it.
>
> I believe Andrew answered the question for you, it's a WIP and we have
> patches to clean that up.

Thanks, yes good to see it being worked on.

> I don't see ppc64 watchdog support in arch/powerpc, is that something
> you are working with on implementing?

I've submitted it over on linuxppc-dev:

http://patchwork.ozlabs.org/patch/406802/

Anton