diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2010-05-07 09:46:50 +0100 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2010-05-07 09:46:50 +0100 |
commit | 40af606c02e8caaa824213a7eb2232c6b166dc88 (patch) | |
tree | ba4af4f8b075b6362101bb7185f2b8b5c5f269fa /xen/include/acpi | |
parent | c4826676c4550e36296f34dc48228cf91af5a86d (diff) | |
download | xen-40af606c02e8caaa824213a7eb2232c6b166dc88.tar.gz xen-40af606c02e8caaa824213a7eb2232c6b166dc88.tar.bz2 xen-40af606c02e8caaa824213a7eb2232c6b166dc88.zip |
x86/cpufreq: fix turbo mode detection
{acpi,powernow}_cpufreq_cpu_init() generally don't run on the CPU the
policy they deal with is related to, hence using cpuid() directly
works only as long as all CPUs in the system are identical (which
admittedly is commonly the case).
Further add a per-policy flag indicating the availability of
APERF/MPERF MSRs, so that globally setting the .getavg accessor won't
be a problem on heterogeneous configurations.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Diffstat (limited to 'xen/include/acpi')
-rw-r--r-- | xen/include/acpi/cpufreq/cpufreq.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/xen/include/acpi/cpufreq/cpufreq.h b/xen/include/acpi/cpufreq/cpufreq.h index 662c1bd3d4..32067e55cb 100644 --- a/xen/include/acpi/cpufreq/cpufreq.h +++ b/xen/include/acpi/cpufreq/cpufreq.h @@ -52,11 +52,12 @@ struct cpufreq_policy { * governors are used */ struct cpufreq_governor *governor; - unsigned int resume; /* flag for cpufreq 1st run + bool_t resume; /* flag for cpufreq 1st run * S3 wakeup, hotplug cpu, etc */ - int turbo; /* tristate flag: 0 for unsupported + s8 turbo; /* tristate flag: 0 for unsupported * -1 for disable, 1 for enabled * See CPUFREQ_TURBO_* below for defines */ + bool_t aperf_mperf; /* CPU has APERF/MPERF MSRs */ }; extern struct cpufreq_policy *cpufreq_cpu_policy[NR_CPUS]; |