From: Aaron Wu Date: Wed, 22 Oct 2014 05:45:58 +0000 (+0800) Subject: pm: sometimes wake up from suspend to RAM would fail X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=3ce321aed10adc2d926560622d0a4ed21cd3b23f;p=deliverable%2Flinux.git pm: sometimes wake up from suspend to RAM would fail Sometimes it fails to wake up from suspend to RAM, this is because we would flush the data cache by assemble command FLUSHINV before suspend to RAM, and there is a delay between this command execution and cache flush completion. Add a 1uS delay to works around this. Signed-off-by: Aaron Wu --- diff --git a/arch/blackfin/mach-common/pm.c b/arch/blackfin/mach-common/pm.c index 1387a94bcfd5..a66d979ec651 100644 --- a/arch/blackfin/mach-common/pm.c +++ b/arch/blackfin/mach-common/pm.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include @@ -180,6 +181,7 @@ int bfin_pm_suspend_mem_enter(void) #if defined(CONFIG_BFIN_EXTMEM_WRITEBACK) || defined(CONFIG_BFIN_L2_WRITEBACK) flushinv_all_dcache(); + udelay(1); #endif _disable_dcplb(); _disable_icplb();