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] Xen PANIC in MCE interrupt context : can global variable dom

To: <Xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Xen PANIC in MCE interrupt context : can global variable dom0 be NULL ?
From: Ashwin Pankaj <ashwin.pankaj@xxxxxxx>
Date: Mon, 15 Feb 2010 19:49:53 +0530
Cc:
Delivery-date: Mon, 15 Feb 2010 06:20:32 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.7) Gecko/20100111 Thunderbird/3.0.1
Hi ,


I am using Xen 3.4.1 - I see that sometimes when an MCE error occurs Xen panics due to a page fault with the following stack trace-

http://pastebin.com/f30f67342

 After some digging, probable culprit seems to be smp_cmci_interrupt

if (bs.errcnt && mctc != NULL) {
if (guest_enabled_event(dom0->vcpu[0], <------------------------------------ here
                     VIRQ_MCA)) {
            mctelem_commit(mctc);
            printk(KERN_DEBUG "CMCI: send CMCI to DOM0 through virq\n");
            send_guest_global_virq(dom0, VIRQ_MCA);
        } else {
            x86_mcinfo_dump(mctelem_dataptr(mctc));
            mctelem_dismiss(mctc);
       }


Looks like dom0 is NULL here ( vcpu[0] offset is 0x468). Is this possible?

Other functions like mce_softirq() perform a NULL check on dom0 before accessing it's members ....
/* Step2: Send Log to DOM0 through vIRQ */
        if (dom0 && guest_enabled_event(dom0->vcpu[0], VIRQ_MCA)) {
            printk(KERN_DEBUG "MCE: send MCE# to DOM0 through virq\n");
            send_guest_global_virq(dom0, VIRQ_MCA);
        }

Also note that, this system printed the MCE warning message( "(XEN) MCE: The hardware reports a non fatal, correctable incident occured on CPU 0" ) twice before panicing.

So this code worked properly and entered x86_mcinfo_dump() atleast twice before panic.


- Regards,
Ashwin



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

<Prev in Thread] Current Thread [Next in Thread>