mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
x86/nmi: Drop K7_NMI_EVENT
This name is misleading. It's not possible to configure NMI or not from the event select register; that comes from the APIC configuration for performance events. This name is "the thing we want to count for the NMI watchdog", but that's clearer to follow when it simply names the event. Drop the indirection. No functional change. Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> Acked-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
1 parent
74d16381e0
commit
ebc00c30c6
1 file changed
+1
-2
+1
-2
@@ -102,7 +102,6 @@ static int nmi_active;
|
|||||||
#define K7_EVNTSEL_OS (1 << 17)
|
#define K7_EVNTSEL_OS (1 << 17)
|
||||||
#define K7_EVNTSEL_USR (1 << 16)
|
#define K7_EVNTSEL_USR (1 << 16)
|
||||||
#define K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING 0x76
|
#define K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING 0x76
|
||||||
#define K7_NMI_EVENT K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING
|
|
||||||
#define K7_EVENT_WIDTH 32
|
#define K7_EVENT_WIDTH 32
|
||||||
|
|
||||||
#define P6_EVNTSEL0_ENABLE (1 << 22)
|
#define P6_EVNTSEL0_ENABLE (1 << 22)
|
||||||
@@ -259,7 +258,7 @@ static void setup_k7_watchdog(void)
|
|||||||
evntsel = K7_EVNTSEL_INT
|
evntsel = K7_EVNTSEL_INT
|
||||||
| K7_EVNTSEL_OS
|
| K7_EVNTSEL_OS
|
||||||
| K7_EVNTSEL_USR
|
| K7_EVNTSEL_USR
|
||||||
| K7_NMI_EVENT;
|
| K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING;
|
||||||
|
|
||||||
wrmsrns(MSR_K7_EVNTSEL0, evntsel);
|
wrmsrns(MSR_K7_EVNTSEL0, evntsel);
|
||||||
write_watchdog_counter("K7_PERFCTR0");
|
write_watchdog_counter("K7_PERFCTR0");
|
||||||
|
|||||||