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] [HVM][SVM] Use proper name for the K8 VM_

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [HVM][SVM] Use proper name for the K8 VM_CR MSR.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 12 Oct 2006 23:00:34 +0000
Delivery-date: Thu, 12 Oct 2006 16:00:59 -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 kfraser@xxxxxxxxxxxxxxxxxxxxx
# Node ID f14a67a35becfb8fb9b455a219fd1a7c942bc21d
# Parent  d845c9522d9e26d7b3cbd6a193d583a47fe3c787
[HVM][SVM] Use proper name for the K8 VM_CR MSR.
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
---
 xen/arch/x86/hvm/svm/svm.c |    7 ++++---
 xen/include/asm-x86/msr.h  |    8 +++++++-
 2 files changed, 11 insertions(+), 4 deletions(-)

diff -r d845c9522d9e -r f14a67a35bec xen/arch/x86/hvm/svm/svm.c
--- a/xen/arch/x86/hvm/svm/svm.c        Thu Oct 12 16:12:10 2006 +0100
+++ b/xen/arch/x86/hvm/svm/svm.c        Thu Oct 12 17:53:51 2006 +0100
@@ -842,12 +842,13 @@ int start_svm(void)
         return 0;
 
     /* check whether SVM feature is disabled in BIOS */
-    rdmsr(0xC0010114, eax, edx);
-    if ( eax & 0x00000010 ) {
+    rdmsr(MSR_K8_VM_CR, eax, edx);
+    if ( eax & K8_VMCR_SVME_DISABLE )
+    {
         printk("AMD SVM Extension is disabled in BIOS.\n");
         return 0;
     }
-    
+
     if (!(hsa[cpu] = alloc_host_save_area()))
         return 0;
     
diff -r d845c9522d9e -r f14a67a35bec xen/include/asm-x86/msr.h
--- a/xen/include/asm-x86/msr.h Thu Oct 12 16:12:10 2006 +0100
+++ b/xen/include/asm-x86/msr.h Thu Oct 12 17:53:51 2006 +0100
@@ -302,8 +302,14 @@ static inline void wrmsrl(unsigned int m
 
 #define MSR_K8_TOP_MEM1                        0xC001001A
 #define MSR_K8_TOP_MEM2                        0xC001001D
+#define MSR_K8_SYSCFG                  0xC0010010
+#define MSR_K8_HWCR                    0xC0010015
+#define MSR_K8_VM_CR                   0xC0010114
 #define MSR_K8_VM_HSAVE_PA             0xC0010117
-#define MSR_K8_SYSCFG                  0xC0000010      
+
+/* MSR_K8_VM_CR bits: */
+#define _K8_VMCR_SVME_DISABLE          4
+#define K8_VMCR_SVME_DISABLE           (1 << _K8_VMCR_SVME_DISABLE)
 
 /* Centaur-Hauls/IDT defined MSRs. */
 #define MSR_IDT_FCR1                   0x107

_______________________________________________
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] [HVM][SVM] Use proper name for the K8 VM_CR MSR., Xen patchbot-unstable <=