[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[xen master] x86/nmi: Drop K7_NMI_EVENT



commit ebc00c30c65023bd1498ae20dc511c4e39f6c0f7
Author:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Tue Aug 4 10:50:11 2026 +0100
Commit:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Mon Aug 17 18:46:08 2026 +0100

    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@xxxxxxxxxx>
    Acked-by: Jan Beulich <jbeulich@xxxxxxxx>
---
 xen/arch/x86/nmi.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/xen/arch/x86/nmi.c b/xen/arch/x86/nmi.c
index 2ec567c114..b71bf43635 100644
--- a/xen/arch/x86/nmi.c
+++ b/xen/arch/x86/nmi.c
@@ -102,7 +102,6 @@ static int nmi_active;
 #define K7_EVNTSEL_OS          (1 << 17)
 #define K7_EVNTSEL_USR         (1 << 16)
 #define K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING   0x76
-#define K7_NMI_EVENT           K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING
 #define K7_EVENT_WIDTH          32
 
 #define P6_EVNTSEL0_ENABLE     (1 << 22)
@@ -259,7 +258,7 @@ static void setup_k7_watchdog(void)
     evntsel = K7_EVNTSEL_INT
         | K7_EVNTSEL_OS
         | K7_EVNTSEL_USR
-        | K7_NMI_EVENT;
+        | K7_EVENT_CYCLES_PROCESSOR_IS_RUNNING;
 
     wrmsrns(MSR_K7_EVNTSEL0, evntsel);
     write_watchdog_counter("K7_PERFCTR0");
--
generated by git-patchbot for /home/xen/git/xen.git#master



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.