aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2012-07-20 02:03:43 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-08-15 08:10:06 -0700
commitea2ebaa71c978254c2a93bf561236aec8a167166 (patch)
tree5b93e476cf4b8c33122821762ed17b0298ac8926
parent05aa0d1bc94e2809ec0ccb4be20860784e4640b1 (diff)
downloadparrot-ea2ebaa71c978254c2a93bf561236aec8a167166.tar.gz
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: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-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 b0197b2c857d1..da3b9292f9f0e 100644
--- a/arch/arm/vfp/vfpmodule.c
+++ b/arch/arm/vfp/vfpmodule.c
@@ -460,7 +460,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;
}