From a27cd62bb4934abe2af420ba7ca5115fbfb653be Mon Sep 17 00:00:00 2001 From: Russell King Date: Thu, 1 Sep 2011 11:57:59 +0100 Subject: ARM: pm: add L2 cache cleaning for suspend We need to ensure that state is pushed out from the L2 cache when suspending so that the resume paths can access their data before the MMU and caches have been re-initialized. Add the necessary calls to __cpu_suspend_save(). Change-Id: Idf7516347478731b722e62a37b5cc9f1c52be68e Tested-by: Santosh Shilimkar Tested-by: Shawn Guo Tested-by: Lorenzo Pieralisi Signed-off-by: Russell King Signed-off-by: Varun Wadekar Reviewed-on: http://git-master/r/85729 Reviewed-by: Automatic_Commit_Validation_User --- arch/arm/kernel/suspend.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'arch/arm') diff --git a/arch/arm/kernel/suspend.c b/arch/arm/kernel/suspend.c index 2d60f1903206..93a22d282c16 100644 --- a/arch/arm/kernel/suspend.c +++ b/arch/arm/kernel/suspend.c @@ -28,6 +28,9 @@ void __cpu_suspend_save(u32 *ptr, u32 ptrsz, u32 sp, u32 *save_ptr) cpu_do_suspend(ptr); flush_cache_all(); + outer_clean_range(*save_ptr, *save_ptr + ptrsz); + outer_clean_range(virt_to_phys(save_ptr), + virt_to_phys(save_ptr) + sizeof(*save_ptr)); } /* -- cgit v1.2.3