[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] IA64: fix fp fault/trap handler.
# HG changeset patch # User Isaku Yamahata <yamahata@xxxxxxxxxxxxx> # Date 1229045658 -32400 # Node ID 9e0f8f78d37a6c80339ed30b64099515211b5ebd # Parent a86a4ddd8b2b06d9906bc8868099b5a7bbb2b53e IA64: fix fp fault/trap handler. This patch is a part of fixes to bug reported as http://bugzilla.xensource.com/bugzilla/show_bug.cgi?id=1392 When fpswa handler fails to get a bundle in guest, fp fault/trap should be injected into the guest and let a guest to handle it. When the fpswa library return a error, there is no way to pass the value to the guest. In that case, just inject fpswa fault/trap into a guest running a risk that guest may get error with their own fpswa call. Here it is assumed that no applications depend on SIGFP process signal to recover their computation. Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx> --- xen/arch/ia64/vmx/vmx_fault.c | 7 +------ xen/arch/ia64/xen/faults.c | 10 ---------- xen/include/asm-ia64/domain.h | 1 - 3 files changed, 1 insertion(+), 17 deletions(-) diff -r a86a4ddd8b2b -r 9e0f8f78d37a xen/arch/ia64/vmx/vmx_fault.c --- a/xen/arch/ia64/vmx/vmx_fault.c Fri Dec 12 10:29:15 2008 +0900 +++ b/xen/arch/ia64/vmx/vmx_fault.c Fri Dec 12 10:34:18 2008 +0900 @@ -122,8 +122,7 @@ void vmx_reflect_interruption(u64 ifa, u if (!status) { vcpu_increment_iip(vcpu); return; - } else if (IA64_RETRY == status) - return; + } break; case 33: // IA64_FP_TRAP_VECTOR @@ -133,10 +132,6 @@ void vmx_reflect_interruption(u64 ifa, u status = handle_fpu_swa(0, regs, isr); if (!status) return; - else if (IA64_RETRY == status) { - vcpu_decrement_iip(vcpu); - return; - } break; case 29: // IA64_DEBUG_VECTOR diff -r a86a4ddd8b2b -r 9e0f8f78d37a xen/arch/ia64/xen/faults.c --- a/xen/arch/ia64/xen/faults.c Fri Dec 12 10:29:15 2008 +0900 +++ b/xen/arch/ia64/xen/faults.c Fri Dec 12 10:34:18 2008 +0900 @@ -314,7 +314,6 @@ unsigned long unsigned long handle_fpu_swa(int fp_fault, struct pt_regs *regs, unsigned long isr) { - struct vcpu *v = current; IA64_BUNDLE bundle; unsigned long fault_ip; fpswa_ret_t ret; @@ -348,7 +347,6 @@ handle_fpu_swa(int fp_fault, struct pt_r &isr, ®s->pr, ®s->cr_ifs, regs); if (ret.status) { - PSCBX(v, fpswa_ret) = ret; printk("%s(%s): fp_emulate() returned %ld\n", __FUNCTION__, fp_fault ? "fault" : "trap", ret.status); } @@ -688,9 +686,6 @@ ia64_handle_reflection(unsigned long ifa vcpu_increment_iip(v); return; } - // fetch code fail - if (IA64_RETRY == status) - return; printk("ia64_handle_reflection: handling FP fault\n"); vector = IA64_FP_FAULT_VECTOR; break; @@ -698,11 +693,6 @@ ia64_handle_reflection(unsigned long ifa status = handle_fpu_swa(0, regs, isr); if (!status) return; - // fetch code fail - if (IA64_RETRY == status) { - vcpu_decrement_iip(v); - return; - } printk("ia64_handle_reflection: handling FP trap\n"); vector = IA64_FP_TRAP_VECTOR; break; diff -r a86a4ddd8b2b -r 9e0f8f78d37a xen/include/asm-ia64/domain.h --- a/xen/include/asm-ia64/domain.h Fri Dec 12 10:29:15 2008 +0900 +++ b/xen/include/asm-ia64/domain.h Fri Dec 12 10:34:18 2008 +0900 @@ -288,7 +288,6 @@ struct arch_vcpu { char irq_new_condition; // vpsr.i/vtpr change, check for pending VHPI char hypercall_continuation; - fpswa_ret_t fpswa_ret; /* save return values of FPSWA emulation */ struct timer hlt_timer; struct arch_vmx_struct arch_vmx; /* Virtual Machine Extensions */ _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |