Loading Documentation/cpu-freq/cpu-drivers.txt +0 −2 Original line number Diff line number Diff line Loading @@ -50,8 +50,6 @@ What shall this struct cpufreq_driver contain? cpufreq_driver.name - The name of this driver. cpufreq_driver.owner - THIS_MODULE; cpufreq_driver.init - A pointer to the per-CPU initialization function. Loading arch/x86/include/asm/processor.h +0 −29 Original line number Diff line number Diff line Loading @@ -942,35 +942,6 @@ extern int set_tsc_mode(unsigned int val); extern u16 amd_get_nb_id(int cpu); struct aperfmperf { u64 aperf, mperf; }; static inline void get_aperfmperf(struct aperfmperf *am) { WARN_ON_ONCE(!boot_cpu_has(X86_FEATURE_APERFMPERF)); rdmsrl(MSR_IA32_APERF, am->aperf); rdmsrl(MSR_IA32_MPERF, am->mperf); } #define APERFMPERF_SHIFT 10 static inline unsigned long calc_aperfmperf_ratio(struct aperfmperf *old, struct aperfmperf *new) { u64 aperf = new->aperf - old->aperf; u64 mperf = new->mperf - old->mperf; unsigned long ratio = aperf; mperf >>= APERFMPERF_SHIFT; if (mperf) ratio = div64_u64(aperf, mperf); return ratio; } extern unsigned long arch_align_stack(unsigned long sp); extern void free_init_pages(char *what, unsigned long begin, unsigned long end); Loading drivers/cpufreq/Kconfig.arm +24 −12 Original line number Diff line number Diff line Loading @@ -17,37 +17,47 @@ config ARM_DT_BL_CPUFREQ big.LITTLE platform. This gets frequency tables from DT. config ARM_EXYNOS_CPUFREQ bool "SAMSUNG EXYNOS SoCs" depends on ARCH_EXYNOS bool select CPU_FREQ_TABLE default y help This adds the CPUFreq driver common part for Samsung EXYNOS SoCs. If in doubt, say N. config ARM_EXYNOS4210_CPUFREQ def_bool CPU_EXYNOS4210 bool "SAMSUNG EXYNOS4210" depends on CPU_EXYNOS4210 default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS4210 SoC (S5PV310 or S5PC210). If in doubt, say N. config ARM_EXYNOS4X12_CPUFREQ def_bool (SOC_EXYNOS4212 || SOC_EXYNOS4412) bool "SAMSUNG EXYNOS4x12" depends on (SOC_EXYNOS4212 || SOC_EXYNOS4412) default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS4X12 SoC (EXYNOS4212 or EXYNOS4412). If in doubt, say N. config ARM_EXYNOS5250_CPUFREQ def_bool SOC_EXYNOS5250 bool "SAMSUNG EXYNOS5250" depends on SOC_EXYNOS5250 default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS5250 SoC. If in doubt, say N. config ARM_EXYNOS5440_CPUFREQ def_bool SOC_EXYNOS5440 bool "SAMSUNG EXYNOS5440" depends on SOC_EXYNOS5440 depends on HAVE_CLK && PM_OPP && OF default y select CPU_FREQ_TABLE help This adds the CPUFreq driver for Samsung EXYNOS5440 Loading @@ -55,6 +65,8 @@ config ARM_EXYNOS5440_CPUFREQ different than previous exynos controllers so not using the common exynos framework. If in doubt, say N. config ARM_HIGHBANK_CPUFREQ tristate "Calxeda Highbank-based" depends on ARCH_HIGHBANK Loading drivers/cpufreq/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ obj-$(CONFIG_GENERIC_CPUFREQ_CPU0) += cpufreq-cpu0.o # powernow-k8 can load then. ACPI is preferred to all other hardware-specific drivers. # speedstep-* is preferred over p4-clockmod. obj-$(CONFIG_X86_ACPI_CPUFREQ) += acpi-cpufreq.o mperf.o obj-$(CONFIG_X86_ACPI_CPUFREQ) += acpi-cpufreq.o obj-$(CONFIG_X86_POWERNOW_K8) += powernow-k8.o obj-$(CONFIG_X86_PCC_CPUFREQ) += pcc-cpufreq.o obj-$(CONFIG_X86_POWERNOW_K6) += powernow-k6.o Loading drivers/cpufreq/acpi-cpufreq.c +3 −9 Original line number Diff line number Diff line Loading @@ -45,7 +45,6 @@ #include <asm/msr.h> #include <asm/processor.h> #include <asm/cpufeature.h> #include "mperf.h" MODULE_AUTHOR("Paul Diefenbaugh, Dominik Brodowski"); MODULE_DESCRIPTION("ACPI Processor P-States Driver"); Loading Loading @@ -198,7 +197,7 @@ static ssize_t show_cpb(struct cpufreq_policy *policy, char *buf) return sprintf(buf, "%u\n", boost_enabled); } static struct freq_attr cpb = __ATTR(cpb, 0644, show_cpb, store_cpb); cpufreq_freq_attr_rw(cpb); #endif static int check_est_cpu(unsigned int cpuid) Loading Loading @@ -710,7 +709,7 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) return blacklisted; #endif data = kzalloc(sizeof(struct acpi_cpufreq_data), GFP_KERNEL); data = kzalloc(sizeof(*data), GFP_KERNEL); if (!data) return -ENOMEM; Loading Loading @@ -800,7 +799,7 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) goto err_unreg; } data->freq_table = kmalloc(sizeof(struct cpufreq_frequency_table) * data->freq_table = kmalloc(sizeof(*data->freq_table) * (perf->state_count+1), GFP_KERNEL); if (!data->freq_table) { result = -ENOMEM; Loading Loading @@ -861,10 +860,6 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) /* notify BIOS that we exist */ acpi_processor_notify_smm(THIS_MODULE); /* Check for APERF/MPERF support in hardware */ if (boot_cpu_has(X86_FEATURE_APERFMPERF)) acpi_cpufreq_driver.getavg = cpufreq_get_measured_perf; pr_debug("CPU%u - ACPI performance management activated.\n", cpu); for (i = 0; i < perf->state_count; i++) pr_debug(" %cP%d: %d MHz, %d mW, %d uS\n", Loading Loading @@ -941,7 +936,6 @@ static struct cpufreq_driver acpi_cpufreq_driver = { .exit = acpi_cpufreq_cpu_exit, .resume = acpi_cpufreq_resume, .name = "acpi-cpufreq", .owner = THIS_MODULE, .attr = acpi_cpufreq_attr, }; Loading Loading
Documentation/cpu-freq/cpu-drivers.txt +0 −2 Original line number Diff line number Diff line Loading @@ -50,8 +50,6 @@ What shall this struct cpufreq_driver contain? cpufreq_driver.name - The name of this driver. cpufreq_driver.owner - THIS_MODULE; cpufreq_driver.init - A pointer to the per-CPU initialization function. Loading
arch/x86/include/asm/processor.h +0 −29 Original line number Diff line number Diff line Loading @@ -942,35 +942,6 @@ extern int set_tsc_mode(unsigned int val); extern u16 amd_get_nb_id(int cpu); struct aperfmperf { u64 aperf, mperf; }; static inline void get_aperfmperf(struct aperfmperf *am) { WARN_ON_ONCE(!boot_cpu_has(X86_FEATURE_APERFMPERF)); rdmsrl(MSR_IA32_APERF, am->aperf); rdmsrl(MSR_IA32_MPERF, am->mperf); } #define APERFMPERF_SHIFT 10 static inline unsigned long calc_aperfmperf_ratio(struct aperfmperf *old, struct aperfmperf *new) { u64 aperf = new->aperf - old->aperf; u64 mperf = new->mperf - old->mperf; unsigned long ratio = aperf; mperf >>= APERFMPERF_SHIFT; if (mperf) ratio = div64_u64(aperf, mperf); return ratio; } extern unsigned long arch_align_stack(unsigned long sp); extern void free_init_pages(char *what, unsigned long begin, unsigned long end); Loading
drivers/cpufreq/Kconfig.arm +24 −12 Original line number Diff line number Diff line Loading @@ -17,37 +17,47 @@ config ARM_DT_BL_CPUFREQ big.LITTLE platform. This gets frequency tables from DT. config ARM_EXYNOS_CPUFREQ bool "SAMSUNG EXYNOS SoCs" depends on ARCH_EXYNOS bool select CPU_FREQ_TABLE default y help This adds the CPUFreq driver common part for Samsung EXYNOS SoCs. If in doubt, say N. config ARM_EXYNOS4210_CPUFREQ def_bool CPU_EXYNOS4210 bool "SAMSUNG EXYNOS4210" depends on CPU_EXYNOS4210 default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS4210 SoC (S5PV310 or S5PC210). If in doubt, say N. config ARM_EXYNOS4X12_CPUFREQ def_bool (SOC_EXYNOS4212 || SOC_EXYNOS4412) bool "SAMSUNG EXYNOS4x12" depends on (SOC_EXYNOS4212 || SOC_EXYNOS4412) default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS4X12 SoC (EXYNOS4212 or EXYNOS4412). If in doubt, say N. config ARM_EXYNOS5250_CPUFREQ def_bool SOC_EXYNOS5250 bool "SAMSUNG EXYNOS5250" depends on SOC_EXYNOS5250 default y select ARM_EXYNOS_CPUFREQ help This adds the CPUFreq driver for Samsung EXYNOS5250 SoC. If in doubt, say N. config ARM_EXYNOS5440_CPUFREQ def_bool SOC_EXYNOS5440 bool "SAMSUNG EXYNOS5440" depends on SOC_EXYNOS5440 depends on HAVE_CLK && PM_OPP && OF default y select CPU_FREQ_TABLE help This adds the CPUFreq driver for Samsung EXYNOS5440 Loading @@ -55,6 +65,8 @@ config ARM_EXYNOS5440_CPUFREQ different than previous exynos controllers so not using the common exynos framework. If in doubt, say N. config ARM_HIGHBANK_CPUFREQ tristate "Calxeda Highbank-based" depends on ARCH_HIGHBANK Loading
drivers/cpufreq/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ obj-$(CONFIG_GENERIC_CPUFREQ_CPU0) += cpufreq-cpu0.o # powernow-k8 can load then. ACPI is preferred to all other hardware-specific drivers. # speedstep-* is preferred over p4-clockmod. obj-$(CONFIG_X86_ACPI_CPUFREQ) += acpi-cpufreq.o mperf.o obj-$(CONFIG_X86_ACPI_CPUFREQ) += acpi-cpufreq.o obj-$(CONFIG_X86_POWERNOW_K8) += powernow-k8.o obj-$(CONFIG_X86_PCC_CPUFREQ) += pcc-cpufreq.o obj-$(CONFIG_X86_POWERNOW_K6) += powernow-k6.o Loading
drivers/cpufreq/acpi-cpufreq.c +3 −9 Original line number Diff line number Diff line Loading @@ -45,7 +45,6 @@ #include <asm/msr.h> #include <asm/processor.h> #include <asm/cpufeature.h> #include "mperf.h" MODULE_AUTHOR("Paul Diefenbaugh, Dominik Brodowski"); MODULE_DESCRIPTION("ACPI Processor P-States Driver"); Loading Loading @@ -198,7 +197,7 @@ static ssize_t show_cpb(struct cpufreq_policy *policy, char *buf) return sprintf(buf, "%u\n", boost_enabled); } static struct freq_attr cpb = __ATTR(cpb, 0644, show_cpb, store_cpb); cpufreq_freq_attr_rw(cpb); #endif static int check_est_cpu(unsigned int cpuid) Loading Loading @@ -710,7 +709,7 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) return blacklisted; #endif data = kzalloc(sizeof(struct acpi_cpufreq_data), GFP_KERNEL); data = kzalloc(sizeof(*data), GFP_KERNEL); if (!data) return -ENOMEM; Loading Loading @@ -800,7 +799,7 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) goto err_unreg; } data->freq_table = kmalloc(sizeof(struct cpufreq_frequency_table) * data->freq_table = kmalloc(sizeof(*data->freq_table) * (perf->state_count+1), GFP_KERNEL); if (!data->freq_table) { result = -ENOMEM; Loading Loading @@ -861,10 +860,6 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy) /* notify BIOS that we exist */ acpi_processor_notify_smm(THIS_MODULE); /* Check for APERF/MPERF support in hardware */ if (boot_cpu_has(X86_FEATURE_APERFMPERF)) acpi_cpufreq_driver.getavg = cpufreq_get_measured_perf; pr_debug("CPU%u - ACPI performance management activated.\n", cpu); for (i = 0; i < perf->state_count; i++) pr_debug(" %cP%d: %d MHz, %d mW, %d uS\n", Loading Loading @@ -941,7 +936,6 @@ static struct cpufreq_driver acpi_cpufreq_driver = { .exit = acpi_cpufreq_cpu_exit, .resume = acpi_cpufreq_resume, .name = "acpi-cpufreq", .owner = THIS_MODULE, .attr = acpi_cpufreq_attr, }; Loading