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] cpufreq: fix the build

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] cpufreq: fix the build
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 11 Feb 2009 12:31:46 -0800
Delivery-date: Wed, 11 Feb 2009 12:31:56 -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.fraser@xxxxxxxxxx>
# Date 1234370219 0
# Node ID bf9cdbec516ab1ad79e11f277a5bbdd8cb340f3c
# Parent  999c465f94f9d0d4ee74d3b604d25c2ba2d59749
cpufreq: fix the build
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 xen/drivers/cpufreq/cpufreq.c |   24 +++++++++++-------------
 1 files changed, 11 insertions(+), 13 deletions(-)

diff -r 999c465f94f9 -r bf9cdbec516a xen/drivers/cpufreq/cpufreq.c
--- a/xen/drivers/cpufreq/cpufreq.c     Wed Feb 11 13:07:45 2009 +0000
+++ b/xen/drivers/cpufreq/cpufreq.c     Wed Feb 11 16:36:59 2009 +0000
@@ -501,13 +501,12 @@ void __init cpufreq_cmdline_parse(char *
 {
     static struct cpufreq_governor *__initdata cpufreq_governors[] =
     {
-        #define CPUFREQ_DEFAULT_GOVERNOR_INDEX 0;
         &cpufreq_gov_userspace,
         &cpufreq_gov_dbs,
         &cpufreq_gov_performance,
         &cpufreq_gov_powersave
     };
-    unsigned int gov_index = CPUFREQ_DEFAULT_GOVERNOR_INDEX;
+    unsigned int gov_index = 0;
 
     do {
         char *val, *end = strchr(str, ',');
@@ -520,24 +519,23 @@ void __init cpufreq_cmdline_parse(char *
             *val++ = '\0';
 
         if (!cpufreq_opt_governor) {
-            if (!val)
-                for (i = 0; i < ARRAY_SIZE(cpufreq_governors); ++i)
+            if (!val) {
+                for (i = 0; i < ARRAY_SIZE(cpufreq_governors); ++i) {
                     if (!strcmp(str, cpufreq_governors[i]->name)) {
                         cpufreq_opt_governor = cpufreq_governors[i];
                         gov_index = i;
                         str = NULL;
                         break;
                     }
-            else
+                }
+            } else {
                 cpufreq_opt_governor = CPUFREQ_DEFAULT_GOVERNOR;
-        }
-
-        if (str) {
-            if (cpufreq_handle_common_option(str, val))
-                ;
-            else if (cpufreq_governors[gov_index]->handle_option)
-                cpufreq_governors[gov_index]->handle_option(str, val);
-        }
+            }
+        }
+
+        if (str && !cpufreq_handle_common_option(str, val) &&
+            cpufreq_governors[gov_index]->handle_option)
+            cpufreq_governors[gov_index]->handle_option(str, val);
 
         str = end;
     } while (str);

_______________________________________________
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] cpufreq: fix the build, Xen patchbot-unstable <=