[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] [IA64] Enable fast hyperprivop for ssm.i and rfi



# HG changeset patch
# User awilliam@xxxxxxxxxxxx
# Date 1167952462 25200
# Node ID d9cc772c6bde7c3eb13360ddd91a82dc432d8c20
# Parent  eb40e07b867f9708a9c39225ce1591e19808852a
[IA64] Enable fast hyperprivop for ssm.i and rfi

Signed-off-by: Anthony Xu <anthony.xu@xxxxxxxxx>
---
 xen/arch/ia64/asm-offsets.c     |    1 +
 xen/arch/ia64/xen/hyperprivop.S |   22 ++++++++++------------
 2 files changed, 11 insertions(+), 12 deletions(-)

diff -r eb40e07b867f -r d9cc772c6bde xen/arch/ia64/asm-offsets.c
--- a/xen/arch/ia64/asm-offsets.c       Thu Jan 04 16:10:25 2007 -0700
+++ b/xen/arch/ia64/asm-offsets.c       Thu Jan 04 16:14:22 2007 -0700
@@ -60,6 +60,7 @@ void foo(void)
        DEFINE(IA64_VCPU_META_SAVED_RR0_OFFSET, offsetof (struct vcpu, 
arch.metaphysical_saved_rr0));
        DEFINE(IA64_VCPU_BREAKIMM_OFFSET, offsetof (struct vcpu, 
arch.breakimm));
        DEFINE(IA64_VCPU_IVA_OFFSET, offsetof (struct vcpu, arch.iva));
+       DEFINE(IA64_VCPU_EVENT_CALLBACK_IP_OFFSET, offsetof (struct vcpu, 
arch.event_callback_ip));
        DEFINE(IA64_VCPU_IRR0_OFFSET, offsetof (struct vcpu, arch.irr[0]));
        DEFINE(IA64_VCPU_IRR3_OFFSET, offsetof (struct vcpu, arch.irr[3]));
        DEFINE(IA64_VCPU_INSVC3_OFFSET, offsetof (struct vcpu, arch.insvc[3]));
diff -r eb40e07b867f -r d9cc772c6bde xen/arch/ia64/xen/hyperprivop.S
--- a/xen/arch/ia64/xen/hyperprivop.S   Thu Jan 04 16:10:25 2007 -0700
+++ b/xen/arch/ia64/xen/hyperprivop.S   Thu Jan 04 16:14:22 2007 -0700
@@ -37,10 +37,10 @@
 # define FAST_BREAK
 # undef FAST_ACCESS_REFLECT    //XXX TODO fast_access_reflect
                                //    doesn't support dom0 vp yet.
-//# define FAST_RFI
+# define FAST_RFI
 // TODO: Since we use callback to deliver interrupt, 
 //       FAST_SSM_I needs to be rewritten.
-//# define FAST_SSM_I
+# define FAST_SSM_I
 # define FAST_PTC_GA
 # undef RFI_TO_INTERRUPT // not working yet
 #endif
@@ -282,13 +282,11 @@ ENTRY(hyper_ssm_i)
        adds r21=XSI_PRECOVER_IFS_OFS-XSI_PSR_IC_OFS,r18 ;;
        st8 [r21]=r20 ;;
        // leave cr.ifs alone for later rfi
-       // set iip to go to domain IVA break instruction vector
+       // set iip to go to event callback handler
        movl r22=THIS_CPU(cpu_kr)+IA64_KR_CURRENT_OFFSET;;
        ld8 r22=[r22];;
-       adds r22=IA64_VCPU_IVA_OFFSET,r22;;
-       ld8 r23=[r22];;
-       movl r24=0x3000;;
-       add r24=r24,r23;;
+       adds r22=IA64_VCPU_EVENT_CALLBACK_IP_OFFSET,r22;;
+       ld8 r24=[r22];;
        mov cr.iip=r24;;
        // OK, now all set to go except for switch to virtual bank0
        mov r30=r2
@@ -1027,8 +1025,12 @@ ENTRY(hyper_rfi)
        adds r20=XSI_IPSR_OFS-XSI_PSR_IC_OFS,r18 ;;
        ld8 r21=[r20];;         // r21 = vcr.ipsr
        extr.u r22=r21,IA64_PSR_I_BIT,1 ;;
-       mov r30=r22     
+       mov r30=r22;;
        // r30 determines whether we might deliver an immediate extint
+#ifndef RFI_TO_INTERRUPT // see beginning of file
+       cmp.ne p6,p0=r30,r0
+(p6)   br.cond.spnt.few dispatch_break_fault ;;
+#endif
 1:
        adds r20=XSI_IPSR_OFS-XSI_PSR_IC_OFS,r18 ;;
        ld8 r21=[r20];;         // r21 = vcr.ipsr
@@ -1063,10 +1065,6 @@ 1:
        cmp.ltu p0,p7=r22,r23 ;;        // if !(iip<low) &&
 (p7)   cmp.geu p0,p7=r22,r24 ;;        //    !(iip>=high)
 (p7)   br.spnt.few dispatch_break_fault ;;
-#ifndef RFI_TO_INTERRUPT // see beginning of file
-       cmp.ne p6,p0=r30,r0
-(p6)   br.cond.spnt.few dispatch_break_fault ;;
-#endif
 
 1:     // OK now, let's do an rfi.
 #ifdef FAST_HYPERPRIVOP_CNT

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.