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] x86 hvm vpmu: Print error if VPMU cannot

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] x86 hvm vpmu: Print error if VPMU cannot be init'ed on this CPU.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 18 Nov 2010 11:00:37 -0800
Delivery-date: Thu, 18 Nov 2010 11:01:03 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/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 Keir Fraser <keir@xxxxxxx>
# Date 1289907849 0
# Node ID 379123d8dbab42351f9ebf41bcb0a21ef8440c24
# Parent  9b2ca938cfe6c0639471e24634bc4a48d889b412
x86 hvm vpmu: Print error if VPMU cannot be init'ed on this CPU.

Signed-off-by: Dietmar Hahn <dietmar.hahn@xxxxxxxxxxxxxx>
Signed-off-by: Keir Fraser <keir@xxxxxxx>
---
 xen/arch/x86/hvm/vpmu.c |   54 ++++++++++++++++++++++++------------------------
 1 files changed, 27 insertions(+), 27 deletions(-)

diff -r 9b2ca938cfe6 -r 379123d8dbab xen/arch/x86/hvm/vpmu.c
--- a/xen/arch/x86/hvm/vpmu.c   Tue Nov 16 11:28:33 2010 +0000
+++ b/xen/arch/x86/hvm/vpmu.c   Tue Nov 16 11:44:09 2010 +0000
@@ -97,43 +97,43 @@ void vpmu_initialise(struct vcpu *v)
 
     switch ( vendor )
     {
-        case X86_VENDOR_AMD:
+    case X86_VENDOR_AMD:
+        switch ( family )
         {
-            switch ( family )
-            {
-            case 0x10:
-                vpmu->arch_vpmu_ops = &amd_vpmu_ops;
-                break;
-            default:
-                printk("VMPU: Initialization failed. "
-                       "AMD processor family %d has not "
-                       "been supported\n", family);
-                return;
-            }
+        case 0x10:
+            vpmu->arch_vpmu_ops = &amd_vpmu_ops;
+            break;
+        default:
+            printk("VPMU: Initialization failed. "
+                   "AMD processor family %d has not "
+                   "been supported\n", family);
+            return;
         }
         break;
 
-        case X86_VENDOR_INTEL:
+    case X86_VENDOR_INTEL:
+        if ( family == 6 )
         {
-            if ( family == 6 )
+            switch ( cpu_model )
             {
-                switch ( cpu_model )
-                {
-                case 15:
-                case 23:
-                case 26:
-                case 29:
-                    vpmu->arch_vpmu_ops = &core2_vpmu_ops;
-                    break;
-                }
+            case 15:
+            case 23:
+            case 26:
+            case 29:
+                vpmu->arch_vpmu_ops = &core2_vpmu_ops;
+                break;
             }
         }
+        if ( vpmu->arch_vpmu_ops == NULL )
+            printk("VPMU: Initialization failed. "
+                   "Intel processor family %d model %d has not "
+                   "been supported\n", family, cpu_model);
         break;
 
-        default:
-            printk("VMPU: Initialization failed. "
-                   "Unknown CPU vendor %d\n", vendor);
-            return;
+    default:
+        printk("VPMU: Initialization failed. "
+               "Unknown CPU vendor %d\n", vendor);
+        break;
     }
 
     if ( vpmu->arch_vpmu_ops != NULL )

_______________________________________________
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] x86 hvm vpmu: Print error if VPMU cannot be init'ed on this CPU., Xen patchbot-unstable <=