WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] [IA64] Switch to VPS save/restore for HVM

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [IA64] Switch to VPS save/restore for HVM
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 08 Apr 2008 02:00:43 -0700
Delivery-date: Tue, 08 Apr 2008 02:01:27 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Alex Williamson <alex.williamson@xxxxxx>
# Date 1205171459 21600
# Node ID b45f3a99a4bb27a9497bdcb11da89883505d2c54
# Parent  e6d6595d29f73dd4ee3ebc4b85c89104de456325
[IA64] Switch to VPS save/restore for HVM

Replace pal_vp_save/restore with vps_save/restore.
The latter have better performance.

Signed-off-by: Anthony Xu <anthony.xu@xxxxxxxxx>
---
 xen/arch/ia64/vmx/vmx_init.c       |   16 ++++------------
 xen/include/asm-ia64/vmx_pal_vsa.h |    2 ++
 2 files changed, 6 insertions(+), 12 deletions(-)

diff -r e6d6595d29f7 -r b45f3a99a4bb xen/arch/ia64/vmx/vmx_init.c
--- a/xen/arch/ia64/vmx/vmx_init.c      Mon Mar 10 11:27:42 2008 -0600
+++ b/xen/arch/ia64/vmx/vmx_init.c      Mon Mar 10 11:50:59 2008 -0600
@@ -52,6 +52,7 @@
 #include <xen/event.h>
 #include <asm/vlsapic.h>
 #include <asm/vhpt.h>
+#include <asm/vmx_pal_vsa.h>
 #include "entry.h"
 
 /* Global flag to identify whether Intel vmx feature is on */
@@ -308,12 +309,8 @@ vmx_save_state(struct vcpu *v)
        u64 status;
 
        BUG_ON(v != current);
-       /* FIXME: about setting of pal_proc_vector... time consuming */
-       status = ia64_pal_vp_save((u64 *)v->arch.privregs, 0);
-       if (status != PAL_STATUS_SUCCESS){
-               panic_domain(vcpu_regs(v),"Save vp status failed\n");
-       }
-
+       
+       ia64_call_vsa(PAL_VPS_SAVE, v->arch.privregs, 0, 0, 0, 0, 0, 0);
 
        /* Need to save KR when domain switch, though HV itself doesn;t
         * use them.
@@ -332,17 +329,12 @@ void
 void
 vmx_load_state(struct vcpu *v)
 {
-       u64 status;
-
        BUG_ON(v != current);
 
        vmx_load_all_rr(v);
 
        /* vmx_load_all_rr() pins down v->arch.privregs with both dtr/itr*/
-       status = ia64_pal_vp_restore((u64 *)v->arch.privregs, 0);
-       if (status != PAL_STATUS_SUCCESS){
-               panic_domain(vcpu_regs(v),"Restore vp status failed\n");
-       }
+       ia64_call_vsa(PAL_VPS_RESTORE, v->arch.privregs, 0, 0, 0, 0, 0, 0);
 
        ia64_set_kr(0, v->arch.arch_vmx.vkr[0]);
        ia64_set_kr(1, v->arch.arch_vmx.vkr[1]);
diff -r e6d6595d29f7 -r b45f3a99a4bb xen/include/asm-ia64/vmx_pal_vsa.h
--- a/xen/include/asm-ia64/vmx_pal_vsa.h        Mon Mar 10 11:27:42 2008 -0600
+++ b/xen/include/asm-ia64/vmx_pal_vsa.h        Mon Mar 10 11:50:59 2008 -0600
@@ -38,6 +38,8 @@ extern u64 __vsa_base;
 #define PAL_VPS_SET_PENDING_INTERRUPT       0x1000
 #define PAL_VPS_THASH               0x1400
 #define PAL_VPS_TTAG                0x1800
+#define PAL_VPS_RESTORE             0x1c00
+#define PAL_VPS_SAVE                0x2000
 
 #endif /* _PAL_VSA_H_ */
 

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] [IA64] Switch to VPS save/restore for HVM, Xen patchbot-unstable <=