From: Sander Eikelenboom Subject: Re: Using debug-key 'o: Dump IOMMU p2m table, locks up machine Date: Tue, 4 Sep 2012 10:20:24 +0200 Message-ID: <1894818567.20120904102024@eikelenboom.it> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Keir Fraser Cc: George Dunlap , wei.wang2@amd.com, Santosh Jodh , Jan Beulich , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Hello Keir, Tuesday, September 4, 2012, 10:11:42 AM, you wrote: > On 04/09/2012 09:04, "Keir Fraser" wrote: >> On 04/09/2012 08:55, "Jan Beulich" wrote: >> >>>> Jan, Yes you could be right, if Sander is pinning CPUs. Anyway, I wasn't >>>> going to expend too much brain power on this situation. The case of spending >>>> a few minutes in one key handler is not one I think is particularly sane. >>> >>> Which imo would call for reverting the patch. But then again, other >>> key handlers can easily take pretty long too (particularly on large >>> systems, albeit it is clear that the one here is particularly bad), and >>> declaring all of them pretty much useless probably isn't the best >>> choice (as then we could as well rip them all out). >>> >>> Bottom line - _I_ think we should try to do something about this. >>> An apparent option would be to have low priority tasklets (for >>> just this purpose, as all others we certainly want to take priority), >>> if that can reasonably be integrated with the schedulers. >> >> Do you expect to be able to use the log-running key handlers and still need >> a running system afterwards (rather than using them as a final >> dump-everything when the system has already gone bad)? Then I suppose you >> would need something like this, with voluntary preemption in the key >> handlers. You then need to be able to recommence the keyhandlers where they >> left off, retaking locks, finding their place in lists, trees, etc, even >> when state of the system has significantly changed between preemption and >> resumption. Well, I'm sure it can be done, but can anyone be bothered. > My pragmatic take would be that: (a) Really long-running handlers that want > to dump every page mapping of every domain are pretty bloody stupid, and yes > we should consider if they are worthwhile at all; (b) moderately > long-running but useful handlers which nonetheless take a long time to dump > to Xen's console, I would consider a sysctl to allow dom0 to request dump > into a supplied memory buffer. Is it necessary for this case to let it be a key-handler for which one can't specify parameters to limit the output ? In this case both hypervisor and kernel are running fine, so a interface via say "xl debug" should be perfectly fine and providing parameters should be possible ? >> -- Keir >> >>