aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-davinci/cpuidle.c
diff options
context:
space:
mode:
authorDaniel Lezcano <daniel.lezcano@linaro.org>2013-04-03 08:15:19 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-04-08 16:20:06 -0400
commitc062d44311107de7e384e26d7b97803657cf44f8 (patch)
tree8a14bf0fb7a59748364e8debd30f4bad46ab2917 /arch/arm/mach-davinci/cpuidle.c
parent0697598db56179dbaa9376f29703f6b94751a73f (diff)
ARM: davinci: cpuidle: fix wrong enter function
The davinci_enter_idle is called from the cpuidle with the cpuidle_wrap_enter function. This one does the time compution for entering and exiting the idle function and then we call again cpuidle_wrap_enter for cpu_do_idle. This is wrong, we are calling recursively cpuidle_wrap_enter for nothing and furthermore reenabling the local irq. Remove this and replace it by the cpu_do_idle function. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'arch/arm/mach-davinci/cpuidle.c')
-rw-r--r--arch/arm/mach-davinci/cpuidle.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/arch/arm/mach-davinci/cpuidle.c b/arch/arm/mach-davinci/cpuidle.c
index 5ac9e9384b15..22d6d4acc8d9 100644
--- a/arch/arm/mach-davinci/cpuidle.c
+++ b/arch/arm/mach-davinci/cpuidle.c
@@ -50,14 +50,10 @@ static void davinci_save_ddr_power(int enter, bool pdown)
50 50
51/* Actual code that puts the SoC in different idle states */ 51/* Actual code that puts the SoC in different idle states */
52static int davinci_enter_idle(struct cpuidle_device *dev, 52static int davinci_enter_idle(struct cpuidle_device *dev,
53 struct cpuidle_driver *drv, 53 struct cpuidle_driver *drv, int index)
54 int index)
55{ 54{
56 davinci_save_ddr_power(1, ddr2_pdown); 55 davinci_save_ddr_power(1, ddr2_pdown);
57 56 cpu_do_idle();
58 index = cpuidle_wrap_enter(dev, drv, index,
59 arm_cpuidle_simple_enter);
60
61 davinci_save_ddr_power(0, ddr2_pdown); 57 davinci_save_ddr_power(0, ddr2_pdown);
62 58
63 return index; 59 return index;