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] Crashdump and IOMMU problems

To: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Crashdump and IOMMU problems
From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
Date: Wed, 11 May 2011 13:46:42 +0100
Cc: Wei Wang <wei.wang2@xxxxxxx>, Allen Kay <allen.m.kay@xxxxxxxxx>
Delivery-date: Wed, 11 May 2011 05:47:30 -0700
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 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110424 Lightning/1.0b2 Thunderbird/3.1.10
Hello,

I have been debugging kexec interaction problems with XenServer and found that the problem lies in how Xen tares down the computer in a crash.

The Xen kexec path does not touch IOMMU at all, which leaves the kexec native kernel with interrupt remapping enabled without realizing it. This leads to the kexec kernel failing to understand why its interrupts aren't working.

As a debugging measure, I have put iommu_ops->suspend() and iommu_disable_IR() on the kexec path and this 'fixes' the problem, although it is far from safe.

From a correctness point of view, Xen really does need to shutdown all IOMMU remapping before it jumps to the crash kernel. I know that kdump is a "seat of the pants best effort" in the best case, but there is more which Xen needs to do to help it along. I was considering adding a crash_shutdown function to iommu_ops which goes and twiddles the relevant disable bits, without saving state.

However, disabling DMA remapping while transfers are still ongoing is likely asking for trouble. Seeing as people on here are likely to know far more than me on this subject:

1) Is there a systematic way to find and disable active DMA transfers, or indeed a systematic way to shut down PCI (etc) devices which is safe for the kexec path. 2) Are there any other PC subsystems which could do with being shut down in a sensible manor to make life easier for the kdump kernel?

Thanks in advance,

~Andrew

--
Andrew Cooper - Dom0 Kernel Engineer, Citrix XenServer
T: +44 (0)1223 225 900, http://www.citrix.com


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

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