aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2009-01-04 08:18:06 -0500
committerIngo Molnar <mingo@elte.hu>2009-01-06 03:05:31 -0500
commit835481d9bcd65720b473db6b38746a74a3964218 (patch)
treea6f0fa205542cf73a980a2f8e41d5e908a33b6d6 /arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
parent5cb0535f1713b51610f2881b17d0fe3656114364 (diff)
cpumask: convert struct cpufreq_policy to cpumask_var_t
Impact: use new cpumask API to reduce memory usage This is part of an effort to reduce structure sizes for machines configured with large NR_CPUS. cpumask_t gets replaced by cpumask_var_t, which is either struct cpumask[1] (small NR_CPUS) or struct cpumask * (large NR_CPUS). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Mike Travis <travis@sgi.com> Acked-by: Dave Jones <davej@redhat.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c')
-rw-r--r--arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
index 28102ad1a363..0b31939862d6 100644
--- a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
+++ b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
@@ -411,7 +411,7 @@ static int acpi_cpufreq_target(struct cpufreq_policy *policy,
411 411
412#ifdef CONFIG_HOTPLUG_CPU 412#ifdef CONFIG_HOTPLUG_CPU
413 /* cpufreq holds the hotplug lock, so we are safe from here on */ 413 /* cpufreq holds the hotplug lock, so we are safe from here on */
414 cpus_and(online_policy_cpus, cpu_online_map, policy->cpus); 414 cpumask_and(&online_policy_cpus, cpu_online_mask, policy->cpus);
415#else 415#else
416 online_policy_cpus = policy->cpus; 416 online_policy_cpus = policy->cpus;
417#endif 417#endif
@@ -626,15 +626,15 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy)
626 */ 626 */
627 if (policy->shared_type == CPUFREQ_SHARED_TYPE_ALL || 627 if (policy->shared_type == CPUFREQ_SHARED_TYPE_ALL ||
628 policy->shared_type == CPUFREQ_SHARED_TYPE_ANY) { 628 policy->shared_type == CPUFREQ_SHARED_TYPE_ANY) {
629 cpumask_copy(&policy->cpus, perf->shared_cpu_map); 629 cpumask_copy(policy->cpus, perf->shared_cpu_map);
630 } 630 }
631 cpumask_copy(&policy->related_cpus, perf->shared_cpu_map); 631 cpumask_copy(policy->related_cpus, perf->shared_cpu_map);
632 632
633#ifdef CONFIG_SMP 633#ifdef CONFIG_SMP
634 dmi_check_system(sw_any_bug_dmi_table); 634 dmi_check_system(sw_any_bug_dmi_table);
635 if (bios_with_sw_any_bug && cpus_weight(policy->cpus) == 1) { 635 if (bios_with_sw_any_bug && cpumask_weight(policy->cpus) == 1) {
636 policy->shared_type = CPUFREQ_SHARED_TYPE_ALL; 636 policy->shared_type = CPUFREQ_SHARED_TYPE_ALL;
637 policy->cpus = per_cpu(cpu_core_map, cpu); 637 cpumask_copy(policy->cpus, cpu_core_mask(cpu));
638 } 638 }
639#endif 639#endif
640 640