WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] NMI delivery not correctly working

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] NMI delivery not correctly working
From: "Christoph Egger" <Christoph.Egger@xxxxxxx>
Date: Tue, 24 Jul 2007 17:47:23 +0200
Delivery-date: Tue, 24 Jul 2007 08:53:49 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.6
Hi!

The NMI delivery does not work correctly.

In the section process_nmi: in
xen/arch/x86/x86_(32|64)/entry.S you set a bit in VCPU_nmi_masked,
deliver the NMI but not clear VCPU_nmi_masked.

I know, there is a line "current->nmi_masked = 0;" in do_iret() in
xen/arch/x86/x86_(32|64)/traps.c, but this is actually never called
after NMI delivery.

For short: The *first* NMI is actually delivered, but all following NMIs
are NEVER delivered!!

I don't know if this change is correct for 64 bit:

@@ -218,6 +220,7 @@ process_nmi:
         movq %rax,TRAPBOUNCE_eip(%rdx)
         movb $TBF_INTERRUPT,TRAPBOUNCE_flags(%rdx)
         call create_bounce_frame
+        movb  $0, VCPU_nmi_masked(%rbx)
         jmp  test_all_events


and for 32 bit:

@@ -261,6 +262,7 @@ process_nmi:
         movw $FLAT_KERNEL_CS,TRAPBOUNCE_cs(%edx)
         movb $TBF_INTERRUPT,TRAPBOUNCE_flags(%edx)
         call create_bounce_frame
+        movb $0,VCPU_nmi_masked(%ebx)
         jmp  test_all_events

but NMI delivery seems to work with these changes.


Christoph



-- 
AMD Saxony, Dresden, Germany
Operating System Research Center

Legal Information:
AMD Saxony Limited Liability Company & Co. KG
Sitz (Geschäftsanschrift):
   Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland
Registergericht Dresden: HRA 4896
vertretungsberechtigter Komplementär:
   AMD Saxony LLC (Sitz Wilmington, Delaware, USA)
Geschäftsführer der AMD Saxony LLC:
   Dr. Hans-R. Deppe, Thomas McCoy



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel