aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2013-03-25 01:50:23 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-04-10 07:19:26 -0400
commit6eb1c377423572374518f5be93214d139d113090 (patch)
tree3e6163aead961442d07b7f5ad62e58d3e189560c
parent764295ae675bb252de3637e36a6602a9aed7de6b (diff)
cpufreq: powerpc/platforms/cell: move cpufreq driver to drivers/cpufreq
This patch moves cpufreq driver of powerpc platforms/cell to drivers/cpufreq. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
-rw-r--r--arch/powerpc/platforms/cell/Kconfig26
-rw-r--r--arch/powerpc/platforms/cell/Makefile3
-rw-r--r--drivers/cpufreq/Kconfig.powerpc18
-rw-r--r--drivers/cpufreq/Makefile3
-rw-r--r--drivers/cpufreq/ppc_cbe_cpufreq.c (renamed from arch/powerpc/platforms/cell/cbe_cpufreq.c)3
-rw-r--r--drivers/cpufreq/ppc_cbe_cpufreq.h (renamed from arch/powerpc/platforms/cell/cbe_cpufreq.h)4
-rw-r--r--drivers/cpufreq/ppc_cbe_cpufreq_pervasive.c (renamed from arch/powerpc/platforms/cell/cbe_cpufreq_pervasive.c)2
-rw-r--r--drivers/cpufreq/ppc_cbe_cpufreq_pmi.c (renamed from arch/powerpc/platforms/cell/cbe_cpufreq_pmi.c)2
8 files changed, 28 insertions, 33 deletions
diff --git a/arch/powerpc/platforms/cell/Kconfig b/arch/powerpc/platforms/cell/Kconfig
index 53aaefeb3386..9978f594cac0 100644
--- a/arch/powerpc/platforms/cell/Kconfig
+++ b/arch/powerpc/platforms/cell/Kconfig
@@ -113,34 +113,10 @@ config CBE_THERM
113 default m 113 default m
114 depends on CBE_RAS && SPU_BASE 114 depends on CBE_RAS && SPU_BASE
115 115
116config CBE_CPUFREQ
117 tristate "CBE frequency scaling"
118 depends on CBE_RAS && CPU_FREQ
119 default m
120 help
121 This adds the cpufreq driver for Cell BE processors.
122 For details, take a look at <file:Documentation/cpu-freq/>.
123 If you don't have such processor, say N
124
125config CBE_CPUFREQ_PMI_ENABLE
126 bool "CBE frequency scaling using PMI interface"
127 depends on CBE_CPUFREQ
128 default n
129 help
130 Select this, if you want to use the PMI interface
131 to switch frequencies. Using PMI, the
132 processor will not only be able to run at lower speed,
133 but also at lower core voltage.
134
135config CBE_CPUFREQ_PMI
136 tristate
137 depends on CBE_CPUFREQ_PMI_ENABLE
138 default CBE_CPUFREQ
139
140config PPC_PMI 116config PPC_PMI
141 tristate 117 tristate
142 default y 118 default y
143 depends on CBE_CPUFREQ_PMI || PPC_IBM_CELL_POWERBUTTON 119 depends on CPU_FREQ_CBE_PMI || PPC_IBM_CELL_POWERBUTTON
144 help 120 help
145 PMI (Platform Management Interrupt) is a way to 121 PMI (Platform Management Interrupt) is a way to
146 communicate with the BMC (Baseboard Management Controller). 122 communicate with the BMC (Baseboard Management Controller).
diff --git a/arch/powerpc/platforms/cell/Makefile b/arch/powerpc/platforms/cell/Makefile
index a4a89350bcfc..fe053e7c73ee 100644
--- a/arch/powerpc/platforms/cell/Makefile
+++ b/arch/powerpc/platforms/cell/Makefile
@@ -5,9 +5,6 @@ obj-$(CONFIG_PPC_CELL_NATIVE) += iommu.o setup.o spider-pic.o \
5obj-$(CONFIG_CBE_RAS) += ras.o 5obj-$(CONFIG_CBE_RAS) += ras.o
6 6
7obj-$(CONFIG_CBE_THERM) += cbe_thermal.o 7obj-$(CONFIG_CBE_THERM) += cbe_thermal.o
8obj-$(CONFIG_CBE_CPUFREQ_PMI) += cbe_cpufreq_pmi.o
9obj-$(CONFIG_CBE_CPUFREQ) += cbe-cpufreq.o
10cbe-cpufreq-y += cbe_cpufreq_pervasive.o cbe_cpufreq.o
11obj-$(CONFIG_CBE_CPUFREQ_SPU_GOVERNOR) += cpufreq_spudemand.o 8obj-$(CONFIG_CBE_CPUFREQ_SPU_GOVERNOR) += cpufreq_spudemand.o
12 9
13obj-$(CONFIG_PPC_IBM_CELL_POWERBUTTON) += cbe_powerbutton.o 10obj-$(CONFIG_PPC_IBM_CELL_POWERBUTTON) += cbe_powerbutton.o
diff --git a/drivers/cpufreq/Kconfig.powerpc b/drivers/cpufreq/Kconfig.powerpc
index e76992f79683..9c926ca0d718 100644
--- a/drivers/cpufreq/Kconfig.powerpc
+++ b/drivers/cpufreq/Kconfig.powerpc
@@ -1,3 +1,21 @@
1config CPU_FREQ_CBE
2 tristate "CBE frequency scaling"
3 depends on CBE_RAS && PPC_CELL
4 default m
5 help
6 This adds the cpufreq driver for Cell BE processors.
7 For details, take a look at <file:Documentation/cpu-freq/>.
8 If you don't have such processor, say N
9
10config CPU_FREQ_CBE_PMI
11 bool "CBE frequency scaling using PMI interface"
12 depends on CPU_FREQ_CBE
13 default n
14 help
15 Select this, if you want to use the PMI interface to switch
16 frequencies. Using PMI, the processor will not only be able to run at
17 lower speed, but also at lower core voltage.
18
1config CPU_FREQ_MAPLE 19config CPU_FREQ_MAPLE
2 bool "Support for Maple 970FX Evaluation Board" 20 bool "Support for Maple 970FX Evaluation Board"
3 depends on PPC_MAPLE 21 depends on PPC_MAPLE
diff --git a/drivers/cpufreq/Makefile b/drivers/cpufreq/Makefile
index 3a9ff23ff9d9..17417c7ee135 100644
--- a/drivers/cpufreq/Makefile
+++ b/drivers/cpufreq/Makefile
@@ -73,6 +73,9 @@ obj-$(CONFIG_ARCH_TEGRA) += tegra-cpufreq.o
73 73
74################################################################################## 74##################################################################################
75# PowerPC platform drivers 75# PowerPC platform drivers
76obj-$(CONFIG_CPU_FREQ_CBE) += ppc-cbe-cpufreq.o
77ppc-cbe-cpufreq-y += ppc_cbe_cpufreq_pervasive.o ppc_cbe_cpufreq.o
78obj-$(CONFIG_CPU_FREQ_CBE_PMI) += ppc_cbe_cpufreq_pmi.o
76obj-$(CONFIG_CPU_FREQ_MAPLE) += maple-cpufreq.o 79obj-$(CONFIG_CPU_FREQ_MAPLE) += maple-cpufreq.o
77 80
78################################################################################## 81##################################################################################
diff --git a/arch/powerpc/platforms/cell/cbe_cpufreq.c b/drivers/cpufreq/ppc_cbe_cpufreq.c
index 718c6a33023d..e577a1dbbfcd 100644
--- a/arch/powerpc/platforms/cell/cbe_cpufreq.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.c
@@ -27,7 +27,8 @@
27#include <asm/machdep.h> 27#include <asm/machdep.h>
28#include <asm/prom.h> 28#include <asm/prom.h>
29#include <asm/cell-regs.h> 29#include <asm/cell-regs.h>
30#include "cbe_cpufreq.h" 30
31#include "ppc_cbe_cpufreq.h"
31 32
32static DEFINE_MUTEX(cbe_switch_mutex); 33static DEFINE_MUTEX(cbe_switch_mutex);
33 34
diff --git a/arch/powerpc/platforms/cell/cbe_cpufreq.h b/drivers/cpufreq/ppc_cbe_cpufreq.h
index c1d86bfa92ff..b4c00a5a6a59 100644
--- a/arch/powerpc/platforms/cell/cbe_cpufreq.h
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * cbe_cpufreq.h 2 * ppc_cbe_cpufreq.h
3 * 3 *
4 * This file contains the definitions used by the cbe_cpufreq driver. 4 * This file contains the definitions used by the cbe_cpufreq driver.
5 * 5 *
@@ -17,7 +17,7 @@ int cbe_cpufreq_get_pmode(int cpu);
17 17
18int cbe_cpufreq_set_pmode_pmi(int cpu, unsigned int pmode); 18int cbe_cpufreq_set_pmode_pmi(int cpu, unsigned int pmode);
19 19
20#if defined(CONFIG_CBE_CPUFREQ_PMI) || defined(CONFIG_CBE_CPUFREQ_PMI_MODULE) 20#if defined(CONFIG_CPU_FREQ_CBE_PMI) || defined(CONFIG_CPU_FREQ_CBE_PMI_MODULE)
21extern bool cbe_cpufreq_has_pmi; 21extern bool cbe_cpufreq_has_pmi;
22#else 22#else
23#define cbe_cpufreq_has_pmi (0) 23#define cbe_cpufreq_has_pmi (0)
diff --git a/arch/powerpc/platforms/cell/cbe_cpufreq_pervasive.c b/drivers/cpufreq/ppc_cbe_cpufreq_pervasive.c
index 20472e487b6f..84d2f2cf5ba7 100644
--- a/arch/powerpc/platforms/cell/cbe_cpufreq_pervasive.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq_pervasive.c
@@ -30,7 +30,7 @@
30#include <asm/hw_irq.h> 30#include <asm/hw_irq.h>
31#include <asm/cell-regs.h> 31#include <asm/cell-regs.h>
32 32
33#include "cbe_cpufreq.h" 33#include "ppc_cbe_cpufreq.h"
34 34
35/* to write to MIC register */ 35/* to write to MIC register */
36static u64 MIC_Slow_Fast_Timer_table[] = { 36static u64 MIC_Slow_Fast_Timer_table[] = {
diff --git a/arch/powerpc/platforms/cell/cbe_cpufreq_pmi.c b/drivers/cpufreq/ppc_cbe_cpufreq_pmi.c
index 60a07a4f9326..d29e8da396a0 100644
--- a/arch/powerpc/platforms/cell/cbe_cpufreq_pmi.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq_pmi.c
@@ -35,7 +35,7 @@
35#include <asm/time.h> 35#include <asm/time.h>
36#endif 36#endif
37 37
38#include "cbe_cpufreq.h" 38#include "ppc_cbe_cpufreq.h"
39 39
40static u8 pmi_slow_mode_limit[MAX_CBE]; 40static u8 pmi_slow_mode_limit[MAX_CBE];
41 41