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-ia64-devel

[Xen-ia64-devel] [PATCH] Make VTIdomain boot again

To: "Magenheimer, Dan \(HP Labs Fort Collins\)" <dan.magenheimer@xxxxxx>
Subject: [Xen-ia64-devel] [PATCH] Make VTIdomain boot again
From: "Xu, Anthony" <anthony.xu@xxxxxxxxx>
Date: Wed, 8 Feb 2006 17:11:48 +0800
Cc: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 08 Feb 2006 09:22:47 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcYsj7AmEVtlI4naRbOSa3V6gzq13w==
Thread-topic: [Xen-ia64-devel] [PATCH] Make VTIdomain boot again
Hi All,

Since the merge from xen-unstable, there is a small window between
bvt_do_schedule and context_switch in function __enter_schedule, where
interrupt is enabled.

See below scenario:
1. VTI domain accesses legacy IO, VMM gets control, sets VTI-domain into
blocked status and calls __enter_schedule to yield scheduler and wait
QEMU in domain0 to handle IO request.
2. There is a timer interrupt in above window, and this timer interrupt
triggers schedule timer, then in irq_exit function, VMM will do
soft_irq, which in turn will invoke __enter_schedule, thus
__enter_schedule is reentered in VMM, which is not correct.

So the root cause is __enter_schedule is reentered.
The correct way is, soft_irq should be done just before VMM returning to
guest just like in native linux soft-irq is done just before linux
returning to application. But in current implementation soft-irq is done
in irq-exit function.

The reason why xenU can boot is,
xenU is always runable, so it will not be deleted from runqueue, though
__enter_schedule is reentered, no issue appear, as for VTIdomain, when
it does IO operation, it will be set into blocked status and be deleted
from runqueue, which will crash the whole system.

This patch is just a workaround, it makes sure in irq_exit only when VMM
is not in nested interrupted situation, soft_irq is done.

I strongly suggest soft-irq be done in the path of ia64_leave_kernel
just like native linux kernel.

Any comment?

Thanks,
-Anthony 

Attachment: vtidomianboot.patch
Description: vtidomianboot.patch

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
<Prev in Thread] Current Thread [Next in Thread>