summaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorLee Jones <lee.jones@linaro.org>2013-05-16 12:15:35 +0100
committerLinus Walleij <linus.walleij@linaro.org>2013-05-27 14:08:20 +0200
commit2c06897e4597b1cd68ef29e4145917a751c2b4cd (patch)
treebde8a6f158143effaaaea6970f6d5b0e1cb54cb6 /arch/arm
parente4aa937ec75df0eea0bee03bffa3303ad36c986b (diff)
downloadlinux-2c06897e4597b1cd68ef29e4145917a751c2b4cd.tar.gz
linux-2c06897e4597b1cd68ef29e4145917a751c2b4cd.tar.bz2
linux-2c06897e4597b1cd68ef29e4145917a751c2b4cd.zip
ARM: ux500: Only configure wake-up reasons on ux500 based platforms
Multiplatform calls all enabled platforms' initcalls. In the ux500_idle_init() initcall we call into the DBx500-PRCMU which in turn executes some ux500 specific register reads/writes. When running on some !ux500 platforms this ends up causing a kernel Oops. This patch ensures the PRCMU call is only invoked when running on ux500 based platforms. Reported-by: Rob Herring <rob.herring@calxeda.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-ux500/cpuidle.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/mach-ux500/cpuidle.c b/arch/arm/mach-ux500/cpuidle.c
index 317a2be129fb..a45dd09daed9 100644
--- a/arch/arm/mach-ux500/cpuidle.c
+++ b/arch/arm/mach-ux500/cpuidle.c
@@ -21,6 +21,7 @@
#include <asm/proc-fns.h>
#include "db8500-regs.h"
+#include "id.h"
static atomic_t master = ATOMIC_INIT(0);
static DEFINE_SPINLOCK(master_lock);
@@ -114,6 +115,9 @@ static struct cpuidle_driver ux500_idle_driver = {
int __init ux500_idle_init(void)
{
+ if (!(cpu_is_u8500_family() || cpu_is_ux540_family()))
+ return -ENODEV;
+
/* Configure wake up reasons */
prcmu_enable_wakeups(PRCMU_WAKEUP(ARM) | PRCMU_WAKEUP(RTC) |
PRCMU_WAKEUP(ABB));