[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH for-2.9] tco: do not generate an NMI
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH for-2.9] tco: do not generate an NMI |
Date: |
Wed, 5 Apr 2017 15:49:12 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 |
On 05/04/2017 15:35, Laszlo Ersek wrote:
> Yes, I did track it back to SERR#/IOCHK#.
>
> What wasn't obvious to me why the TCO watchdog couldn't activate SERR#.
>
> I guess I missed the "SERR#" explanation in Table-2.6 "PCI Interface
> Signals", where it is described as
>
> System Error: SERR# can be pulsed active by any PCI device that
> detects a system error condition. Upon sampling SERR# active, the
> ICH9 has the ability to generate an NMI, SMI#, or interrupt.
>
> ... Well, I still don't see why the watchdog cannot activate SERR#. Why
> can't it? :)
Because that's not what SERR# is for? :) And especially because the
effect of a watchdog timeout is described elsewhere without including
SERR# in the picture.
>> so that the watchdog does reboot the machine), everything works without
>> ugly messages.
>
> Thanks for the explanation. I now wonder why Paulo decided to add the
> NMI in the first place -- was he too confused by the SERR# definition?
Both Paulo and Paolo were confused. :)
>>> (Idea taken from "Documentation/sysctl/kernel.txt", near "nmi_watchdog"
>>> -- "The NMI watchdog is disabled by default if the kernel is running as
>>> a guest in a KVM virtual machine.")
>>
>> The Linux NMI watchdog is something else, it is obtained by programming
>> a hardware performance counter on every processor. On Linux,
>> performance counters raise NMIs.
>
> Namely, for whatever reason it was wrong to raise an NMI in a KVM guest
> through those performance counters, the same reason would be enough to
> not raise an NMI through the iTCO_wdt driver either.
I think the reason is not that it's wrong; it's that by default KVM
guests do not have performance counters at all.
Paolo