From dd876f2f36671eeaaa18201c5b0e4e4fc750763b Mon Sep 17 00:00:00 2001 From: Thomas Renninger Date: Mon, 1 Sep 2008 14:27:04 +0200 Subject: [PATCH] --- yaml --- r: 117271 b: refs/heads/master c: 910dfae298f7b3dae0e9a52736182a3b0559ca35 h: refs/heads/master i: 117269: 0619ba5afca660f8f3b2f6a7e476e158ee40c6d0 117267: e687ae0f2eae90244576f22adb45453f3704f67b 117263: 9d25993ce2a35464add2b52b7c766f9dd7dda274 v: v3 --- [refs] | 2 +- trunk/drivers/acpi/processor_perflib.c | 18 +++++++++++++++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index e1a1eeca1580..3f9d2f79a4c1 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a0ad05c75aa362c91f4d9cd91ff375a739574dd8 +refs/heads/master: 910dfae298f7b3dae0e9a52736182a3b0559ca35 diff --git a/trunk/drivers/acpi/processor_perflib.c b/trunk/drivers/acpi/processor_perflib.c index 80c251ec6d2a..242f8143008a 100644 --- a/trunk/drivers/acpi/processor_perflib.c +++ b/trunk/drivers/acpi/processor_perflib.c @@ -38,6 +38,7 @@ #include #endif +#include #include #include @@ -334,7 +335,6 @@ static int acpi_processor_get_performance_info(struct acpi_processor *pr) acpi_status status = AE_OK; acpi_handle handle = NULL; - if (!pr || !pr->performance || !pr->handle) return -EINVAL; @@ -347,13 +347,25 @@ static int acpi_processor_get_performance_info(struct acpi_processor *pr) result = acpi_processor_get_performance_control(pr); if (result) - return result; + goto update_bios; result = acpi_processor_get_performance_states(pr); if (result) - return result; + goto update_bios; return 0; + + /* + * Having _PPC but missing frequencies (_PSS, _PCT) is a very good hint that + * the BIOS is older than the CPU and does not know its frequencies + */ + update_bios: + if (ACPI_SUCCESS(acpi_get_handle(pr->handle, "_PPC", &handle))){ + if(boot_cpu_has(X86_FEATURE_EST)) + printk(KERN_WARNING FW_BUG "BIOS needs update for CPU " + "frequency support\n"); + } + return result; } int acpi_processor_notify_smm(struct module *calling_module)