From: awilliam@xenbuild.aw Date: Tue, 29 Aug 2006 14:09:28 +0000 (-0600) Subject: [IA64] init the hlt timer on a valid cpu and migrate X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~15680 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=2dc8f01c020c79da15dfafacf5fc11a16c62ba6a;p=xen.git [IA64] init the hlt timer on a valid cpu and migrate Based on a patch from Anthony Xu, v->processor is not initialized in alloc_vcpu_struct() when we initialize the hlt_timer. Init the timer on the first cpu and migrate it in schedule_tail(). Signed-off-by: Alex Williamson --- diff --git a/xen/arch/ia64/xen/domain.c b/xen/arch/ia64/xen/domain.c index 0fadeffad0..719af71ff2 100644 --- a/xen/arch/ia64/xen/domain.c +++ b/xen/arch/ia64/xen/domain.c @@ -122,6 +122,7 @@ void schedule_tail(struct vcpu *prev) shared_info->vcpu_info[current->vcpu_id].evtchn_upcall_mask; __ia64_per_cpu_var(current_psr_ic_addr) = (int *) (current->domain->arch.shared_info_va + XSI_PSR_IC_OFS); + migrate_timer(¤t->arch.hlt_timer, current->processor); } flush_vtlb_for_context_switch(current); } @@ -305,7 +306,8 @@ struct vcpu *alloc_vcpu_struct(struct domain *d, unsigned int vcpu_id) v->arch.last_processor = INVALID_PROCESSOR; } if (!VMX_DOMAIN(v)){ - init_timer(&v->arch.hlt_timer, hlt_timer_fn, v, v->processor); + init_timer(&v->arch.hlt_timer, hlt_timer_fn, v, + first_cpu(cpu_online_map)); } return v;