Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powernow-k8: Replace cpu_core_mask() with topology_core_cpumask()

The former duplicates the functionality of the latter but is
neither documented nor arch-independent.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Acked-by: Rafael J. Wysocki <rjw@rjwysocki.net>
Cc: Benoit Cousson <bcousson@baylibre.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Jean Delvare <jdelvare@suse.de>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Oleg Drokin <oleg.drokin@intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1432645896-12588-5-git-send-email-bgolaszewski@baylibre.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>

authored by

Bartosz Golaszewski and committed by
Ingo Molnar
38c52e63 19a34eea

+3 -10
+3 -10
drivers/cpufreq/powernow-k8.c
··· 57 57 58 58 static struct cpufreq_driver cpufreq_amd64_driver; 59 59 60 - #ifndef CONFIG_SMP 61 - static inline const struct cpumask *cpu_core_mask(int cpu) 62 - { 63 - return cpumask_of(0); 64 - } 65 - #endif 66 - 67 60 /* Return a frequency in MHz, given an input fid */ 68 61 static u32 find_freq_from_fid(u32 fid) 69 62 { ··· 613 620 614 621 pr_debug("cfid 0x%x, cvid 0x%x\n", data->currfid, data->currvid); 615 622 data->powernow_table = powernow_table; 616 - if (cpumask_first(cpu_core_mask(data->cpu)) == data->cpu) 623 + if (cpumask_first(topology_core_cpumask(data->cpu)) == data->cpu) 617 624 print_basics(data); 618 625 619 626 for (j = 0; j < data->numps; j++) ··· 777 784 CPUFREQ_TABLE_END; 778 785 data->powernow_table = powernow_table; 779 786 780 - if (cpumask_first(cpu_core_mask(data->cpu)) == data->cpu) 787 + if (cpumask_first(topology_core_cpumask(data->cpu)) == data->cpu) 781 788 print_basics(data); 782 789 783 790 /* notify BIOS that we exist */ ··· 1083 1090 if (rc != 0) 1084 1091 goto err_out_exit_acpi; 1085 1092 1086 - cpumask_copy(pol->cpus, cpu_core_mask(pol->cpu)); 1093 + cpumask_copy(pol->cpus, topology_core_cpumask(pol->cpu)); 1087 1094 data->available_cores = pol->cpus; 1088 1095 1089 1096 /* min/max the cpu is capable of */