aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-exynos
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2014-07-26 11:54:21 -0400
committerArnd Bergmann <arnd@arndb.de>2014-07-26 11:54:21 -0400
commit944483d0330bb497549977aa9649be6b7d0ede37 (patch)
tree545d9c5498e0dbe7697b36ad50379a815b48ec1b /arch/arm/mach-exynos
parent03eea7cda20128f97fa281650ada69fe19194d56 (diff)
parentfd9f5edf6e7e8a666f3672fd809f3289c2da388a (diff)
Merge branch 'next/fixes-non-critical' into next/soc
This resolves a nontrivial conflict against a bug fix in another branch. Conflicts: arch/arm/mach-exynos/pm.c Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mach-exynos')
-rw-r--r--arch/arm/mach-exynos/platsmp.c66
-rw-r--r--arch/arm/mach-exynos/pm.c66
2 files changed, 66 insertions, 66 deletions
diff --git a/arch/arm/mach-exynos/platsmp.c b/arch/arm/mach-exynos/platsmp.c
index 7c829989859c..2207598ce049 100644
--- a/arch/arm/mach-exynos/platsmp.c
+++ b/arch/arm/mach-exynos/platsmp.c
@@ -33,6 +33,72 @@
33 33
34extern void exynos4_secondary_startup(void); 34extern void exynos4_secondary_startup(void);
35 35
36/**
37 * exynos_core_power_down : power down the specified cpu
38 * @cpu : the cpu to power down
39 *
40 * Power down the specified cpu. The sequence must be finished by a
41 * call to cpu_do_idle()
42 *
43 */
44void exynos_cpu_power_down(int cpu)
45{
46 pmu_raw_writel(0, EXYNOS_ARM_CORE_CONFIGURATION(cpu));
47}
48
49/**
50 * exynos_cpu_power_up : power up the specified cpu
51 * @cpu : the cpu to power up
52 *
53 * Power up the specified cpu
54 */
55void exynos_cpu_power_up(int cpu)
56{
57 pmu_raw_writel(S5P_CORE_LOCAL_PWR_EN,
58 EXYNOS_ARM_CORE_CONFIGURATION(cpu));
59}
60
61/**
62 * exynos_cpu_power_state : returns the power state of the cpu
63 * @cpu : the cpu to retrieve the power state from
64 *
65 */
66int exynos_cpu_power_state(int cpu)
67{
68 return (pmu_raw_readl(EXYNOS_ARM_CORE_STATUS(cpu)) &
69 S5P_CORE_LOCAL_PWR_EN);
70}
71
72/**
73 * exynos_cluster_power_down : power down the specified cluster
74 * @cluster : the cluster to power down
75 */
76void exynos_cluster_power_down(int cluster)
77{
78 pmu_raw_writel(0, EXYNOS_COMMON_CONFIGURATION(cluster));
79}
80
81/**
82 * exynos_cluster_power_up : power up the specified cluster
83 * @cluster : the cluster to power up
84 */
85void exynos_cluster_power_up(int cluster)
86{
87 pmu_raw_writel(S5P_CORE_LOCAL_PWR_EN,
88 EXYNOS_COMMON_CONFIGURATION(cluster));
89}
90
91/**
92 * exynos_cluster_power_state : returns the power state of the cluster
93 * @cluster : the cluster to retrieve the power state from
94 *
95 */
96int exynos_cluster_power_state(int cluster)
97{
98 return (pmu_raw_readl(EXYNOS_COMMON_STATUS(cluster)) &
99 S5P_CORE_LOCAL_PWR_EN);
100}
101
36static inline void __iomem *cpu_boot_reg_base(void) 102static inline void __iomem *cpu_boot_reg_base(void)
37{ 103{
38 if (soc_is_exynos4210() && samsung_rev() == EXYNOS4210_REV_1_1) 104 if (soc_is_exynos4210() && samsung_rev() == EXYNOS4210_REV_1_1)
diff --git a/arch/arm/mach-exynos/pm.c b/arch/arm/mach-exynos/pm.c
index c4c6d98ada52..3e046a986e60 100644
--- a/arch/arm/mach-exynos/pm.c
+++ b/arch/arm/mach-exynos/pm.c
@@ -100,72 +100,6 @@ static int exynos_irq_set_wake(struct irq_data *data, unsigned int state)
100 return -ENOENT; 100 return -ENOENT;
101} 101}
102 102
103/**
104 * exynos_core_power_down : power down the specified cpu
105 * @cpu : the cpu to power down
106 *
107 * Power down the specified cpu. The sequence must be finished by a
108 * call to cpu_do_idle()
109 *
110 */
111void exynos_cpu_power_down(int cpu)
112{
113 pmu_raw_writel(0, EXYNOS_ARM_CORE_CONFIGURATION(cpu));
114}
115
116/**
117 * exynos_cpu_power_up : power up the specified cpu
118 * @cpu : the cpu to power up
119 *
120 * Power up the specified cpu
121 */
122void exynos_cpu_power_up(int cpu)
123{
124 pmu_raw_writel(S5P_CORE_LOCAL_PWR_EN,
125 EXYNOS_ARM_CORE_CONFIGURATION(cpu));
126}
127
128/**
129 * exynos_cpu_power_state : returns the power state of the cpu
130 * @cpu : the cpu to retrieve the power state from
131 *
132 */
133int exynos_cpu_power_state(int cpu)
134{
135 return (pmu_raw_readl(EXYNOS_ARM_CORE_STATUS(cpu)) &
136 S5P_CORE_LOCAL_PWR_EN);
137}
138
139/**
140 * exynos_cluster_power_down : power down the specified cluster
141 * @cluster : the cluster to power down
142 */
143void exynos_cluster_power_down(int cluster)
144{
145 pmu_raw_writel(0, EXYNOS_COMMON_CONFIGURATION(cluster));
146}
147
148/**
149 * exynos_cluster_power_up : power up the specified cluster
150 * @cluster : the cluster to power up
151 */
152void exynos_cluster_power_up(int cluster)
153{
154 pmu_raw_writel(S5P_CORE_LOCAL_PWR_EN,
155 EXYNOS_COMMON_CONFIGURATION(cluster));
156}
157
158/**
159 * exynos_cluster_power_state : returns the power state of the cluster
160 * @cluster : the cluster to retrieve the power state from
161 *
162 */
163int exynos_cluster_power_state(int cluster)
164{
165 return (pmu_raw_readl(EXYNOS_COMMON_STATUS(cluster)) &
166 S5P_CORE_LOCAL_PWR_EN);
167}
168
169#define EXYNOS_BOOT_VECTOR_ADDR (samsung_rev() == EXYNOS4210_REV_1_1 ? \ 103#define EXYNOS_BOOT_VECTOR_ADDR (samsung_rev() == EXYNOS4210_REV_1_1 ? \
170 pmu_base_addr + S5P_INFORM7 : \ 104 pmu_base_addr + S5P_INFORM7 : \
171 (samsung_rev() == EXYNOS4210_REV_1_0 ? \ 105 (samsung_rev() == EXYNOS4210_REV_1_0 ? \