diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-30 18:21:02 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-30 18:21:02 -0400 |
| commit | 3ed1c478eff8db80e234d5446cb378b503135888 (patch) | |
| tree | e1c8e0f488ca49c49b5a31fe59add4254381dd4b /arch/unicore32/kernel | |
| parent | 151173e8ce9b95bbbbd7eedb9035cfaffbdb7cb2 (diff) | |
| parent | 371deb9500831ad1afbf9ea00e373f650deaed2f (diff) | |
Merge tag 'pm+acpi-3.10-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull power management and ACPI updates from Rafael J Wysocki:
- ARM big.LITTLE cpufreq driver from Viresh Kumar.
- exynos5440 cpufreq driver from Amit Daniel Kachhap.
- cpufreq core cleanup and code consolidation from Viresh Kumar and
Stratos Karafotis.
- cpufreq scalability improvement from Nathan Zimmer.
- AMD "frequency sensitivity feedback" powersave bias for the ondemand
cpufreq governor from Jacob Shin.
- cpuidle code consolidation and cleanups from Daniel Lezcano.
- ARM OMAP cpuidle fixes from Santosh Shilimkar and Daniel Lezcano.
- ACPICA fixes and other improvements from Bob Moore, Jung-uk Kim, Lv
Zheng, Yinghai Lu, Tang Chen, Colin Ian King, and Linn Crosetto.
- ACPI core updates related to hotplug from Toshi Kani, Paul Bolle,
Yasuaki Ishimatsu, and Rafael J Wysocki.
- Intel Lynxpoint LPSS (Low-Power Subsystem) support improvements from
Rafael J Wysocki and Andy Shevchenko.
* tag 'pm+acpi-3.10-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (192 commits)
cpufreq: Revert incorrect commit 5800043
cpufreq: MAINTAINERS: Add co-maintainer
cpuidle: add maintainer entry
ACPI / thermal: do not always return THERMAL_TREND_RAISING for active trip points
ARM: s3c64xx: cpuidle: use init/exit common routine
cpufreq: pxa2xx: initialize variables
ACPI: video: correct acpi_video_bus_add error processing
SH: cpuidle: use init/exit common routine
ARM: S5pv210: compiling issue, ARM_S5PV210_CPUFREQ needs CONFIG_CPU_FREQ_TABLE=y
ACPI: Fix wrong parameter passed to memblock_reserve
cpuidle: fix comment format
pnp: use %*phC to dump small buffers
isapnp: remove debug leftovers
ARM: imx: cpuidle: use init/exit common routine
ARM: davinci: cpuidle: use init/exit common routine
ARM: kirkwood: cpuidle: use init/exit common routine
ARM: calxeda: cpuidle: use init/exit common routine
ARM: tegra: cpuidle: use init/exit common routine for tegra3
ARM: tegra: cpuidle: use init/exit common routine for tegra2
ARM: OMAP4: cpuidle: use init/exit common routine
...
Diffstat (limited to 'arch/unicore32/kernel')
| -rw-r--r-- | arch/unicore32/kernel/Makefile | 1 | ||||
| -rw-r--r-- | arch/unicore32/kernel/cpu-ucv2.c | 93 |
2 files changed, 0 insertions, 94 deletions
diff --git a/arch/unicore32/kernel/Makefile b/arch/unicore32/kernel/Makefile index fa497e0efe5a..607a72f2ae35 100644 --- a/arch/unicore32/kernel/Makefile +++ b/arch/unicore32/kernel/Makefile | |||
| @@ -9,7 +9,6 @@ obj-y += setup.o signal.o sys.o stacktrace.o traps.o | |||
| 9 | obj-$(CONFIG_MODULES) += ksyms.o module.o | 9 | obj-$(CONFIG_MODULES) += ksyms.o module.o |
| 10 | obj-$(CONFIG_EARLY_PRINTK) += early_printk.o | 10 | obj-$(CONFIG_EARLY_PRINTK) += early_printk.o |
| 11 | 11 | ||
| 12 | obj-$(CONFIG_CPU_FREQ) += cpu-ucv2.o | ||
| 13 | obj-$(CONFIG_UNICORE_FPU_F64) += fpu-ucf64.o | 12 | obj-$(CONFIG_UNICORE_FPU_F64) += fpu-ucf64.o |
| 14 | 13 | ||
| 15 | # obj-y for architecture PKUnity v3 | 14 | # obj-y for architecture PKUnity v3 |
diff --git a/arch/unicore32/kernel/cpu-ucv2.c b/arch/unicore32/kernel/cpu-ucv2.c deleted file mode 100644 index 4a99f62584c7..000000000000 --- a/arch/unicore32/kernel/cpu-ucv2.c +++ /dev/null | |||
| @@ -1,93 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * linux/arch/unicore32/kernel/cpu-ucv2.c: clock scaling for the UniCore-II | ||
| 3 | * | ||
| 4 | * Code specific to PKUnity SoC and UniCore ISA | ||
| 5 | * | ||
| 6 | * Maintained by GUAN Xue-tao <gxt@mprc.pku.edu.cn> | ||
| 7 | * Copyright (C) 2001-2010 Guan Xuetao | ||
| 8 | * | ||
| 9 | * This program is free software; you can redistribute it and/or modify | ||
| 10 | * it under the terms of the GNU General Public License version 2 as | ||
| 11 | * published by the Free Software Foundation. | ||
| 12 | */ | ||
| 13 | |||
| 14 | #include <linux/kernel.h> | ||
| 15 | #include <linux/types.h> | ||
| 16 | #include <linux/init.h> | ||
| 17 | #include <linux/clk.h> | ||
| 18 | #include <linux/cpufreq.h> | ||
| 19 | |||
| 20 | #include <mach/hardware.h> | ||
| 21 | |||
| 22 | static struct cpufreq_driver ucv2_driver; | ||
| 23 | |||
| 24 | /* make sure that only the "userspace" governor is run | ||
| 25 | * -- anything else wouldn't make sense on this platform, anyway. | ||
| 26 | */ | ||
| 27 | int ucv2_verify_speed(struct cpufreq_policy *policy) | ||
| 28 | { | ||
| 29 | if (policy->cpu) | ||
| 30 | return -EINVAL; | ||
| 31 | |||
| 32 | cpufreq_verify_within_limits(policy, | ||
| 33 | policy->cpuinfo.min_freq, policy->cpuinfo.max_freq); | ||
| 34 | |||
| 35 | return 0; | ||
| 36 | } | ||
| 37 | |||
| 38 | static unsigned int ucv2_getspeed(unsigned int cpu) | ||
| 39 | { | ||
| 40 | struct clk *mclk = clk_get(NULL, "MAIN_CLK"); | ||
| 41 | |||
| 42 | if (cpu) | ||
| 43 | return 0; | ||
| 44 | return clk_get_rate(mclk)/1000; | ||
| 45 | } | ||
| 46 | |||
| 47 | static int ucv2_target(struct cpufreq_policy *policy, | ||
| 48 | unsigned int target_freq, | ||
| 49 | unsigned int relation) | ||
| 50 | { | ||
| 51 | unsigned int cur = ucv2_getspeed(0); | ||
| 52 | struct cpufreq_freqs freqs; | ||
| 53 | struct clk *mclk = clk_get(NULL, "MAIN_CLK"); | ||
| 54 | |||
| 55 | cpufreq_notify_transition(&freqs, CPUFREQ_PRECHANGE); | ||
| 56 | |||
| 57 | if (!clk_set_rate(mclk, target_freq * 1000)) { | ||
| 58 | freqs.old = cur; | ||
| 59 | freqs.new = target_freq; | ||
| 60 | freqs.cpu = 0; | ||
| 61 | } | ||
| 62 | |||
| 63 | cpufreq_notify_transition(&freqs, CPUFREQ_POSTCHANGE); | ||
| 64 | |||
| 65 | return 0; | ||
| 66 | } | ||
| 67 | |||
| 68 | static int __init ucv2_cpu_init(struct cpufreq_policy *policy) | ||
| 69 | { | ||
| 70 | if (policy->cpu != 0) | ||
| 71 | return -EINVAL; | ||
| 72 | policy->cur = ucv2_getspeed(0); | ||
| 73 | policy->min = policy->cpuinfo.min_freq = 250000; | ||
| 74 | policy->max = policy->cpuinfo.max_freq = 1000000; | ||
| 75 | policy->cpuinfo.transition_latency = CPUFREQ_ETERNAL; | ||
| 76 | return 0; | ||
| 77 | } | ||
| 78 | |||
| 79 | static struct cpufreq_driver ucv2_driver = { | ||
| 80 | .flags = CPUFREQ_STICKY, | ||
| 81 | .verify = ucv2_verify_speed, | ||
| 82 | .target = ucv2_target, | ||
| 83 | .get = ucv2_getspeed, | ||
| 84 | .init = ucv2_cpu_init, | ||
| 85 | .name = "UniCore-II", | ||
| 86 | }; | ||
| 87 | |||
| 88 | static int __init ucv2_cpufreq_init(void) | ||
| 89 | { | ||
| 90 | return cpufreq_register_driver(&ucv2_driver); | ||
| 91 | } | ||
| 92 | |||
| 93 | arch_initcall(ucv2_cpufreq_init); | ||
