diff options
-rw-r--r-- | arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c index aec3161abede..208ecf6643df 100644 --- a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c +++ b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c | |||
@@ -65,7 +65,6 @@ enum { | |||
65 | struct acpi_cpufreq_data { | 65 | struct acpi_cpufreq_data { |
66 | struct acpi_processor_performance *acpi_data; | 66 | struct acpi_processor_performance *acpi_data; |
67 | struct cpufreq_frequency_table *freq_table; | 67 | struct cpufreq_frequency_table *freq_table; |
68 | unsigned int max_freq; | ||
69 | unsigned int resume; | 68 | unsigned int resume; |
70 | unsigned int cpu_feature; | 69 | unsigned int cpu_feature; |
71 | }; | 70 | }; |
@@ -340,7 +339,7 @@ static unsigned int get_measured_perf(struct cpufreq_policy *policy, | |||
340 | 339 | ||
341 | #endif | 340 | #endif |
342 | 341 | ||
343 | retval = (per_cpu(drv_data, policy->cpu)->max_freq * perf_percent) / 100; | 342 | retval = (policy->cpuinfo.max_freq * perf_percent) / 100; |
344 | 343 | ||
345 | return retval; | 344 | return retval; |
346 | } | 345 | } |
@@ -698,7 +697,6 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) | |||
698 | " latency at 20 uS\n"); | 697 | " latency at 20 uS\n"); |
699 | } | 698 | } |
700 | 699 | ||
701 | data->max_freq = perf->states[0].core_frequency * 1000; | ||
702 | /* table init */ | 700 | /* table init */ |
703 | for (i = 0; i < perf->state_count; i++) { | 701 | for (i = 0; i < perf->state_count; i++) { |
704 | if (i > 0 && perf->states[i].core_frequency >= | 702 | if (i > 0 && perf->states[i].core_frequency >= |
@@ -717,6 +715,9 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) | |||
717 | if (result) | 715 | if (result) |
718 | goto err_freqfree; | 716 | goto err_freqfree; |
719 | 717 | ||
718 | if (perf->states[0].core_frequency * 1000 != policy->cpuinfo.max_freq) | ||
719 | printk(KERN_WARNING FW_WARN "P-state 0 is not max freq\n"); | ||
720 | |||
720 | switch (perf->control_register.space_id) { | 721 | switch (perf->control_register.space_id) { |
721 | case ACPI_ADR_SPACE_SYSTEM_IO: | 722 | case ACPI_ADR_SPACE_SYSTEM_IO: |
722 | /* Current speed is unknown and not detectable by IO port */ | 723 | /* Current speed is unknown and not detectable by IO port */ |