aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2005-12-21 14:05:15 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-12-21 14:05:15 -0500
commitbee5ab3f572d9499c42e75b958ff7309ff830a13 (patch)
treeec48438ed1a7b3d3794a0a4cc577d0bab69b7f03 /drivers
parentb05948d9b7167e23af88cc65b9ffa4687eaf1f0d (diff)
parent5b2db367a28c12e8dfd0b404d9ea35e948c5d7b3 (diff)
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
Diffstat (limited to 'drivers')
-rw-r--r--drivers/acpi/processor_idle.c20
1 files changed, 15 insertions, 5 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c
index 5f51057518b0..807b0df308f1 100644
--- a/drivers/acpi/processor_idle.c
+++ b/drivers/acpi/processor_idle.c
@@ -274,8 +274,6 @@ static void acpi_processor_idle(void)
274 } 274 }
275 } 275 }
276 276
277 cx->usage++;
278
279#ifdef CONFIG_HOTPLUG_CPU 277#ifdef CONFIG_HOTPLUG_CPU
280 /* 278 /*
281 * Check for P_LVL2_UP flag before entering C2 and above on 279 * Check for P_LVL2_UP flag before entering C2 and above on
@@ -283,9 +281,12 @@ static void acpi_processor_idle(void)
283 * detection phase, to work cleanly with logical CPU hotplug. 281 * detection phase, to work cleanly with logical CPU hotplug.
284 */ 282 */
285 if ((cx->type != ACPI_STATE_C1) && (num_online_cpus() > 1) && 283 if ((cx->type != ACPI_STATE_C1) && (num_online_cpus() > 1) &&
286 !pr->flags.has_cst && acpi_fadt.plvl2_up) 284 !pr->flags.has_cst && !acpi_fadt.plvl2_up)
287 cx->type = ACPI_STATE_C1; 285 cx = &pr->power.states[ACPI_STATE_C1];
288#endif 286#endif
287
288 cx->usage++;
289
289 /* 290 /*
290 * Sleep: 291 * Sleep:
291 * ------ 292 * ------
@@ -386,6 +387,15 @@ static void acpi_processor_idle(void)
386 387
387 next_state = pr->power.state; 388 next_state = pr->power.state;
388 389
390#ifdef CONFIG_HOTPLUG_CPU
391 /* Don't do promotion/demotion */
392 if ((cx->type == ACPI_STATE_C1) && (num_online_cpus() > 1) &&
393 !pr->flags.has_cst && !acpi_fadt.plvl2_up) {
394 next_state = cx;
395 goto end;
396 }
397#endif
398
389 /* 399 /*
390 * Promotion? 400 * Promotion?
391 * ---------- 401 * ----------
@@ -557,7 +567,7 @@ static int acpi_processor_get_power_info_fadt(struct acpi_processor *pr)
557 * Check for P_LVL2_UP flag before entering C2 and above on 567 * Check for P_LVL2_UP flag before entering C2 and above on
558 * an SMP system. 568 * an SMP system.
559 */ 569 */
560 if ((num_online_cpus() > 1) && acpi_fadt.plvl2_up) 570 if ((num_online_cpus() > 1) && !acpi_fadt.plvl2_up)
561 return_VALUE(-ENODEV); 571 return_VALUE(-ENODEV);
562#endif 572#endif
563 573