diff options
author | Mike Travis <travis@sgi.com> | 2008-06-09 19:22:23 -0400 |
---|---|---|
committer | Andi Kleen <andi@basil.nowhere.org> | 2008-07-16 17:27:01 -0400 |
commit | 706546d02384b64e083bd9130c56eaa599c66038 (patch) | |
tree | f660fa259f7c8f93a1427cdef529a6ffe8331cab /drivers/acpi/processor_idle.c | |
parent | 5411552c707f4b7387ad63141ef3a559e7488091 (diff) |
ACPI: change processors from array to per_cpu variable
Change processors from an array sized by NR_CPUS to a per_cpu variable.
Signed-off-by: Mike Travis <travis@sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Diffstat (limited to 'drivers/acpi/processor_idle.c')
-rw-r--r-- | drivers/acpi/processor_idle.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c index 4976e5db2b3f..0fc310e7dfd6 100644 --- a/drivers/acpi/processor_idle.c +++ b/drivers/acpi/processor_idle.c | |||
@@ -401,7 +401,7 @@ static void acpi_processor_idle(void) | |||
401 | */ | 401 | */ |
402 | local_irq_disable(); | 402 | local_irq_disable(); |
403 | 403 | ||
404 | pr = processors[smp_processor_id()]; | 404 | pr = __get_cpu_var(processors); |
405 | if (!pr) { | 405 | if (!pr) { |
406 | local_irq_enable(); | 406 | local_irq_enable(); |
407 | return; | 407 | return; |
@@ -1431,7 +1431,7 @@ static int acpi_idle_enter_c1(struct cpuidle_device *dev, | |||
1431 | struct acpi_processor *pr; | 1431 | struct acpi_processor *pr; |
1432 | struct acpi_processor_cx *cx = cpuidle_get_statedata(state); | 1432 | struct acpi_processor_cx *cx = cpuidle_get_statedata(state); |
1433 | 1433 | ||
1434 | pr = processors[smp_processor_id()]; | 1434 | pr = __get_cpu_var(processors); |
1435 | 1435 | ||
1436 | if (unlikely(!pr)) | 1436 | if (unlikely(!pr)) |
1437 | return 0; | 1437 | return 0; |
@@ -1471,7 +1471,7 @@ static int acpi_idle_enter_simple(struct cpuidle_device *dev, | |||
1471 | u32 t1, t2; | 1471 | u32 t1, t2; |
1472 | int sleep_ticks = 0; | 1472 | int sleep_ticks = 0; |
1473 | 1473 | ||
1474 | pr = processors[smp_processor_id()]; | 1474 | pr = __get_cpu_var(processors); |
1475 | 1475 | ||
1476 | if (unlikely(!pr)) | 1476 | if (unlikely(!pr)) |
1477 | return 0; | 1477 | return 0; |
@@ -1549,7 +1549,7 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, | |||
1549 | u32 t1, t2; | 1549 | u32 t1, t2; |
1550 | int sleep_ticks = 0; | 1550 | int sleep_ticks = 0; |
1551 | 1551 | ||
1552 | pr = processors[smp_processor_id()]; | 1552 | pr = __get_cpu_var(processors); |
1553 | 1553 | ||
1554 | if (unlikely(!pr)) | 1554 | if (unlikely(!pr)) |
1555 | return 0; | 1555 | return 0; |