ia64/xen-unstable

changeset 12015:0a490cf4b21d

[IA64] Remove ar.rsc save/restore code in HV

The patch remove codes which save/restore ar.rsc to/from vcpu->arch.old_rsc
when guest doing memory mode switch (virtual -> physical or physical->virtual).
Due to HV is transparent to guest, so there is no need to save/restore ar.rsc
by HV and guest kernel will do that while switching memory mode.

Signed-off-by: Zhang Xin <xing.z.zhang@intel.com>
author awilliam@xenbuild.aw
date Thu Nov 02 12:38:54 2006 -0700 (2006-11-02)
parents 9c649ca5c1cc
children 2fe5df7670cf
files xen/arch/ia64/vmx/vmx_phy_mode.c xen/include/asm-ia64/domain.h
line diff
     1.1 --- a/xen/arch/ia64/vmx/vmx_phy_mode.c	Tue Oct 31 22:25:40 2006 -0700
     1.2 +++ b/xen/arch/ia64/vmx/vmx_phy_mode.c	Thu Nov 02 12:38:54 2006 -0700
     1.3 @@ -100,7 +100,6 @@ int mm_switch_table[8][8] = {
     1.4  void
     1.5  physical_mode_init(VCPU *vcpu)
     1.6  {
     1.7 -    vcpu->arch.old_rsc = 0;
     1.8      vcpu->arch.mode_flags = GUEST_IN_PHY;
     1.9  }
    1.10  
    1.11 @@ -245,13 +244,11 @@ switch_mm_mode(VCPU *vcpu, IA64_PSR old_
    1.12      case SW_V2P:
    1.13  //        printk("V -> P mode transition: (0x%lx -> 0x%lx)\n",
    1.14  //               old_psr.val, new_psr.val);
    1.15 -        vcpu->arch.old_rsc = regs->ar_rsc;
    1.16          switch_to_physical_rid(vcpu);
    1.17          /*
    1.18           * Set rse to enforced lazy, to prevent active rse save/restor when
    1.19           * guest physical mode.
    1.20           */
    1.21 -        regs->ar_rsc &= ~(IA64_RSC_MODE);
    1.22          vcpu->arch.mode_flags |= GUEST_IN_PHY;
    1.23          break;
    1.24      case SW_P2V:
    1.25 @@ -262,7 +259,6 @@ switch_mm_mode(VCPU *vcpu, IA64_PSR old_
    1.26           * recover old mode which is saved when entering
    1.27           * guest physical mode
    1.28           */
    1.29 -        regs->ar_rsc = vcpu->arch.old_rsc;
    1.30          vcpu->arch.mode_flags &= ~GUEST_IN_PHY;
    1.31          break;
    1.32      case SW_SELF:
     2.1 --- a/xen/include/asm-ia64/domain.h	Tue Oct 31 22:25:40 2006 -0700
     2.2 +++ b/xen/include/asm-ia64/domain.h	Thu Nov 02 12:38:54 2006 -0700
     2.3 @@ -186,7 +186,6 @@ struct arch_vcpu {
     2.4      char hypercall_continuation;
     2.5  
     2.6      //for phycial  emulation
     2.7 -    unsigned long old_rsc;
     2.8      int mode_flags;
     2.9      fpswa_ret_t fpswa_ret;	/* save return values of FPSWA emulation */
    2.10      struct timer hlt_timer;