aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVenkatesh Pallipadi <venkatesh.pallipadi@intel.com>2007-09-16 09:36:43 -0400
committerThomas Gleixner <tglx@chaos.(none)>2007-09-16 09:36:43 -0400
commit729c6ba334771f28a54efd7e3b8f5ab9414ce7bc (patch)
tree172a04173bf158d4e8e264cdf9360fa19e71faef
parent6a669ee8a790487b7ec1edda762d39615a78264b (diff)
ACPI: Reevaluate C/P/T states when a cpu becomes online
Reevaluate C/P/T states when a cpu becomes online. This avoids the caching of the broadcast information in the clockevents layer. Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Len Brown <len.brown@intel.com>
-rw-r--r--drivers/acpi/processor_core.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/acpi/processor_core.c b/drivers/acpi/processor_core.c
index e944aaee4e06..2afb3d2086b3 100644
--- a/drivers/acpi/processor_core.c
+++ b/drivers/acpi/processor_core.c
@@ -724,6 +724,25 @@ static void acpi_processor_notify(acpi_handle handle, u32 event, void *data)
724 return; 724 return;
725} 725}
726 726
727static int acpi_cpu_soft_notify(struct notifier_block *nfb,
728 unsigned long action, void *hcpu)
729{
730 unsigned int cpu = (unsigned long)hcpu;
731 struct acpi_processor *pr = processors[cpu];
732
733 if (action == CPU_ONLINE && pr) {
734 acpi_processor_ppc_has_changed(pr);
735 acpi_processor_cst_has_changed(pr);
736 acpi_processor_tstate_has_changed(pr);
737 }
738 return NOTIFY_OK;
739}
740
741static struct notifier_block acpi_cpu_notifier =
742{
743 .notifier_call = acpi_cpu_soft_notify,
744};
745
727static int acpi_processor_add(struct acpi_device *device) 746static int acpi_processor_add(struct acpi_device *device)
728{ 747{
729 struct acpi_processor *pr = NULL; 748 struct acpi_processor *pr = NULL;
@@ -987,6 +1006,7 @@ void acpi_processor_install_hotplug_notify(void)
987 ACPI_UINT32_MAX, 1006 ACPI_UINT32_MAX,
988 processor_walk_namespace_cb, &action, NULL); 1007 processor_walk_namespace_cb, &action, NULL);
989#endif 1008#endif
1009 register_hotcpu_notifier(&acpi_cpu_notifier);
990} 1010}
991 1011
992static 1012static
@@ -999,6 +1019,7 @@ void acpi_processor_uninstall_hotplug_notify(void)
999 ACPI_UINT32_MAX, 1019 ACPI_UINT32_MAX,
1000 processor_walk_namespace_cb, &action, NULL); 1020 processor_walk_namespace_cb, &action, NULL);
1001#endif 1021#endif
1022 unregister_hotcpu_notifier(&acpi_cpu_notifier);
1002} 1023}
1003 1024
1004/* 1025/*