[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH] x86 hvm: fix missing ticks issue in c/s 20218
Although c/s 20229 fixes missing ticks issue in c/s 20218, it's not enough. - set a timer to the next period more straightforwardly. - fix an unexpected behavior of both timer_mode=2 and timer_mode=3. extra interrupts might be delivered to a guest. Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx> diff -r 0f8376078dc1 xen/arch/x86/hvm/vpt.c --- a/xen/arch/x86/hvm/vpt.c Wed Sep 23 18:19:30 2009 +0100 +++ b/xen/arch/x86/hvm/vpt.c Thu Sep 24 17:19:56 2009 +0900 @@ -313,20 +313,23 @@ void pt_intr_post(struct vcpu *v, struct if ( mode_is(v->domain, one_missed_tick_pending) || mode_is(v->domain, no_missed_ticks_pending) ) { + pt_process_missed_ticks(pt); + set_timer(&pt->timer, pt->scheduled); + pt->last_plt_gtime = hvm_get_guest_time(v); pt->pending_intr_nr = 0; /* 'collapse' all missed ticks */ } else { + s_time_t now = NOW(); + + if ( pt->scheduled > now ) + { + set_timer(&pt->timer, pt->scheduled); + pt->pending_intr_nr = 0; + } + pt->last_plt_gtime += pt->period; - pt->pending_intr_nr--; - } - - if ( pt->pending_intr_nr == 0 ) - { - pt_process_missed_ticks(pt); - pt->do_not_freeze = 0; - set_timer(&pt->timer, pt->scheduled); } } _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |