[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] x86/cpuidle: restrict scope of mwait_ptr in acpi_dead_idle()
# HG changeset patch # User Jan Beulich <jbeulich@xxxxxxxx> # Date 1331046719 -3600 # Node ID fb70e48ee3c2ea7060a97d9ddaa6dfc864f1efc0 # Parent 8964c223836c2889364aa75cb1a662ff5eacd5d8 x86/cpuidle: restrict scope of mwait_ptr in acpi_dead_idle() ... just to make sure it doesn't get used improperly (resulting from the discussion around what became c/s 24968:8964c223836c). Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Acked-by: Keir Fraser <keir@xxxxxxx> --- diff -r 8964c223836c -r fb70e48ee3c2 xen/arch/x86/acpi/cpu_idle.c --- a/xen/arch/x86/acpi/cpu_idle.c Tue Mar 06 15:51:33 2012 +0100 +++ b/xen/arch/x86/acpi/cpu_idle.c Tue Mar 06 16:11:59 2012 +0100 @@ -565,7 +565,6 @@ { struct acpi_processor_power *power; struct acpi_processor_cx *cx; - void *mwait_ptr; if ( (power = processor_powers[smp_processor_id()]) == NULL ) goto default_halt; @@ -573,10 +572,10 @@ if ( (cx = &power->states[power->count-1]) == NULL ) goto default_halt; - mwait_ptr = (void *)&mwait_wakeup(smp_processor_id()); - if ( cx->entry_method == ACPI_CSTATE_EM_FFH ) { + void *mwait_ptr = &mwait_wakeup(smp_processor_id()); + /* * Cache must be flushed as the last operation before sleeping. * Otherwise, CPU may still hold dirty data, breaking cache coherency, _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |