diff options
author | Scott Williams <scwilliams@nvidia.com> | 2011-07-28 18:31:21 -0700 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2011-11-30 21:46:59 -0800 |
commit | d0883fc0c9fac21322141df265019a121e79579d (patch) | |
tree | a9f5482000ae945f01ee606573cf6d7b859535e5 /arch/arm/mach-tegra/pm.c | |
parent | 3a83ad92158b2daa2e03b7e9f62ba0a55c444205 (diff) |
ARM: tegra: power: Add debug checks for LP2 entry/exit
Add debug traps for recursive attempts to enter or exit LP2 state.
Change-Id: I7da05774c90a4fd5b9f2369e801c5b447024698f
Signed-off-by: Scott Williams <scwilliams@nvidia.com>
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
Rebase-Id: Rb74239b3fbabf80cf7548c6f5958b0c540ae6b62
Diffstat (limited to 'arch/arm/mach-tegra/pm.c')
-rw-r--r-- | arch/arm/mach-tegra/pm.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/pm.c b/arch/arm/mach-tegra/pm.c index b4d8dd37e850..1514abd042c8 100644 --- a/arch/arm/mach-tegra/pm.c +++ b/arch/arm/mach-tegra/pm.c @@ -412,6 +412,7 @@ static void suspend_cpu_complex(u32 mode) void tegra_clear_cpu_in_lp2(int cpu) { spin_lock(&tegra_lp2_lock); + BUG_ON(!cpumask_test_cpu(cpu, &tegra_in_lp2)); cpumask_clear_cpu(cpu, &tegra_in_lp2); /* Update the IRAM copy used by the reset handler. The IRAM copy @@ -428,6 +429,7 @@ bool tegra_set_cpu_in_lp2(int cpu) bool last_cpu = false; spin_lock(&tegra_lp2_lock); + BUG_ON(cpumask_test_cpu(cpu, &tegra_in_lp2)); cpumask_set_cpu(cpu, &tegra_in_lp2); /* Update the IRAM copy used by the reset handler. The IRAM copy |