Skip to content

Commit

Permalink
pm: sometimes wake up from suspend to RAM would fail
Browse files Browse the repository at this point in the history
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 <Aaron.wu@analog.com>
  • Loading branch information
Aaron Wu authored and Steven Miao committed Apr 23, 2015
1 parent bb717b3 commit ef7dcaf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/blackfin/mach-common/pm.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#include <linux/slab.h>
#include <linux/io.h>
#include <linux/irq.h>
#include <linux/delay.h>

#include <asm/cplb.h>
#include <asm/gpio.h>
Expand Down Expand Up @@ -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();
Expand Down

0 comments on commit ef7dcaf

Please sign in to comment.