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: cpufreq init cleanup

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] x86: cpufreq init cleanup
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Thu, 16 Jun 2011 11:12:08 +0100
Delivery-date: Thu, 16 Jun 2011 03:21:49 -0700
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 Liu, Jinsong <jinsong.liu@xxxxxxxxx>
# Date 1306846434 -3600
# Node ID 773a6ce557f70ac8505dad52f1fd9f45f37c267a
# Parent  7ba15e5287df13b40f675cffc13f8f569339e1a3
x86: cpufreq init cleanup

c/s 20325 change AMD cpufreq init logic.  Before that, AMD cpu start
cpufreq init logic only when all cpus ready.  c/s 20325 change it to
per cpu add, however, leave code un-elegant.

This patch do a little cleanup work.

Signed-off-by: Liu, Jinsong <jinsong.liu@xxxxxxxxx>
---


diff -r 7ba15e5287df -r 773a6ce557f7 xen/arch/x86/acpi/cpufreq/cpufreq.c
--- a/xen/arch/x86/acpi/cpufreq/cpufreq.c       Tue May 31 13:52:42 2011 +0100
+++ b/xen/arch/x86/acpi/cpufreq/cpufreq.c       Tue May 31 13:53:54 2011 +0100
@@ -695,15 +695,11 @@
 
 int cpufreq_cpu_init(unsigned int cpuid)
 {
-    static int cpu_count=0;
     int ret;
 
-    cpu_count++; 
-
     /* Currently we only handle Intel and AMD processor */
-    if ( boot_cpu_data.x86_vendor == X86_VENDOR_INTEL )
-        ret = cpufreq_add_cpu(cpuid);
-    else if ( boot_cpu_data.x86_vendor == X86_VENDOR_AMD )
+    if ( (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL ) ||
+         (boot_cpu_data.x86_vendor == X86_VENDOR_AMD ) )
         ret = cpufreq_add_cpu(cpuid);
     else
         ret = -EFAULT;

_______________________________________________
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: cpufreq init cleanup, Xen patchbot-unstable <=