# HG changeset patch # User gingold@xxxxxxxxxxxxxxxxxxxxx # Node ID aef8a58ff2af0683f0a1002c5ff80582cd84f7a2 # Parent c22741d000a5a812ea93c199c3f5a3cc4ab04d4a save/restore irq instead of disable/enable in vcpu_safe_set_itm. This function is called during context switch, which expect no interrupts. diff -r c22741d000a5 -r aef8a58ff2af xen/arch/ia64/xen/vcpu.c --- a/xen/arch/ia64/xen/vcpu.c Thu Sep 29 23:29:23 2005 +++ b/xen/arch/ia64/xen/vcpu.c Tue Oct 4 10:54:12 2005 @@ -1059,9 +1059,10 @@ void vcpu_safe_set_itm(unsigned long val) { unsigned long epsilon = 100; + unsigned long flags; UINT64 now = ia64_get_itc(); - local_irq_disable(); + local_irq_save(flags); while (1) { //printf("*** vcpu_safe_set_itm: Setting itm to %lx, itc=%lx\n",val,now); ia64_set_itm(val); @@ -1069,7 +1070,7 @@ val = now + epsilon; epsilon <<= 1; } - local_irq_enable(); + local_irq_restore(flags); } void vcpu_set_next_timer(VCPU *vcpu) @@ -1212,6 +1213,7 @@ return (vcpu_deliverable_timer(vcpu) && (now < itm)); } +#if 0 //FIXME: This is a hack because everything dies if a timer tick is lost void vcpu_poke_timer(VCPU *vcpu) { @@ -1237,6 +1239,7 @@ } } } +#endif /**************************************************************************