aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2012-07-20 02:03:43 +0100
committerBen Hutchings <ben@decadent.org.uk>2012-08-10 00:25:04 +0100
commitfc257bc543a3b08545e2332574a12893f0e54c85 (patch)
tree1a545a75eb8e35498078a81c19730f0403bea3d2
parentc51cf2421d129a98183c2e9fd2209fa96297f118 (diff)
ARM: 7476/1: vfp: only clear vfp state for current cpu in vfp_pm_suspend
commit a84b895a2348f0dbff31b71ddf954f70a6cde368 upstream. vfp_pm_suspend runs on each cpu, only clear the hardware state pointer for the current cpu. Prevents a possible crash if one cpu clears the hw state pointer when another cpu has already checked if it is valid. Signed-off-by: Colin Cross <ccross@android.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
-rw-r--r--arch/arm/vfp/vfpmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/vfp/vfpmodule.c b/arch/arm/vfp/vfpmodule.c
index 8ea07e41004..61e11cea9f7 100644
--- a/arch/arm/vfp/vfpmodule.c
+++ b/arch/arm/vfp/vfpmodule.c
@@ -456,7 +456,7 @@ static int vfp_pm_suspend(void)
}
/* clear any information we had about last context state */
- memset(vfp_current_hw_state, 0, sizeof(vfp_current_hw_state));
+ vfp_current_hw_state[ti->cpu] = NULL;
return 0;
}